home *** CD-ROM | disk | FTP | other *** search
Text File | 2000-04-09 | 118.3 KB | 4,550 lines |
- TABLE OF CONTENTS
-
- PowerUPKernel/PPCAdd64
- PowerUPKernel/PPCAdd64p
- PowerUPKernel/PPCAddHead
- PowerUPKernel/PPCAddHeadSync
- PowerUPKernel/PPCAddPortList
- PowerUPKernel/PPCAddTail
- PowerUPKernel/PPCAddTailSync
- PowerUPKernel/PPCAllocMem
- PowerUPKernel/PPCAllocPooled
- PowerUPKernel/PPCAllocSignal
- PowerUPKernel/PPCAllocVec
- PowerUPKernel/PPCAllocVecPooled
- PowerUPKernel/PPCAnd64
- PowerUPKernel/PPCAnd64p
- PowerUPKernel/PPCAsl64
- PowerUPKernel/PPCAsl64p
- PowerUPKernel/PPCAsr64
- PowerUPKernel/PPCAsr64p
- PowerUPKernel/PPCAttemptSemaphore
- PowerUPKernel/PPCAttemptSemaphoreByName
- PowerUPKernel/PPCAttemptSemaphoreShared
- PowerUPKernel/PPCCacheFlush
- PowerUPKernel/PPCCacheFlushAll
- PowerUPKernel/PPCCacheInvalid
- PowerUPKernel/PPCCallM68k
- PowerUPKernel/PPCCallOS
- PowerUPKernel/PPCClose
- PowerUPKernel/PPCCloseLibrary
- PowerUPKernel/PPCCmp64
- PowerUPKernel/PPCCmp64p
- PowerUPKernel/PPCCoerceMethodA
- PowerUPKernel/PPCCreateMessage
- PowerUPKernel/PPCCreatePool
- PowerUPKernel/PPCCreatePort
- PowerUPKernel/PPCCreatePortList
- PowerUPKernel/PPCCreateSemaphore
- PowerUPKernel/PPCCreateTask
- PowerUPKernel/PPCCreateTimerObject
- PowerUPKernel/PPCDeleteMessage
- PowerUPKernel/PPCDeletePool
- PowerUPKernel/PPCDeletePort
- PowerUPKernel/PPCDeletePortList
- PowerUPKernel/PPCDeleteSemaphore
- PowerUPKernel/PPCDeleteTimerObject
- PowerUPKernel/PPCDivRem64
- PowerUPKernel/PPCDivRem64p
- PowerUPKernel/PPCDivs64
- PowerUPKernel/PPCDivs64p
- PowerUPKernel/PPCDivu64
- PowerUPKernel/PPCDivu64p
- PowerUPKernel/PPCDoMethodA
- PowerUPKernel/PPCDoSuperMethodA
- PowerUPKernel/PPCEnqueue
- PowerUPKernel/PPCEnqueueSync
- PowerUPKernel/PPCFindName
- PowerUPKernel/PPCFindNameSync
- PowerUPKernel/PPCFindTagItem
- PowerUPKernel/PPCFindTask
- PowerUPKernel/PPCFinishTask
- PowerUPKernel/PPCfprintf
- PowerUPKernel/PPCFreeMem
- PowerUPKernel/PPCFreePooled
- PowerUPKernel/PPCFreeSignal
- PowerUPKernel/PPCFreeVec
- PowerUPKernel/PPCFreeVecPooled
- PowerUPKernel/PPCGetAttr
- PowerUPKernel/PPCGetLibSymbol
- PowerUPKernel/PPCGetMessage
- PowerUPKernel/PPCGetMessageAttr
- PowerUPKernel/PPCGetObjectAttrs
- PowerUPKernel/PPCGetPortListAttr
- PowerUPKernel/PPCGetTagData
- PowerUPKernel/PPCGetTaskAttr
- PowerUPKernel/PPCGetTimerObject
- PowerUPKernel/PPCInsert
- PowerUPKernel/PPCInsertSync
- PowerUPKernel/PPCkprintf
- PowerUPKernel/PPCLoadObject
- PowerUPKernel/PPCLoadObjectTagList
- PowerUPKernel/PPCLsl64
- PowerUPKernel/PPCLsl64p
- PowerUPKernel/PPCLsr64
- PowerUPKernel/PPCLsr64p
- PowerUPKernel/PPCMods64
- PowerUPKernel/PPCMods64p
- PowerUPKernel/PPCModu64
- PowerUPKernel/PPCModu64p
- PowerUPKernel/PPCMuls64
- PowerUPKernel/PPCMuls64p
- PowerUPKernel/PPCMulu64
- PowerUPKernel/PPCMulu64p
- PowerUPKernel/PPCNeg64
- PowerUPKernel/PPCNeg64p
- PowerUPKernel/PPCNewList
- PowerUPKernel/PPCNextTagItem
- PowerUPKernel/PPCObtainPort
- PowerUPKernel/PPCObtainSemaphore
- PowerUPKernel/PPCObtainSemaphoreByName
- PowerUPKernel/PPCObtainSemaphoreShared
- PowerUPKernel/PPCOpen
- PowerUPKernel/PPCOpenLibrary
- PowerUPKernel/PPCOr64
- PowerUPKernel/PPCOr64p
- PowerUPKernel/PPCprintf
- PowerUPKernel/PPCRawDoFmt
- PowerUPKernel/PPCRead
- PowerUPKernel/PPCReadByte
- PowerUPKernel/PPCReadLong
- PowerUPKernel/PPCReadWord
- PowerUPKernel/PPCReleasePort
- PowerUPKernel/PPCReleaseSemaphore
- PowerUPKernel/PPCRemHead
- PowerUPKernel/PPCRemHeadSync
- PowerUPKernel/PPCRemove
- PowerUPKernel/PPCRemoveSync
- PowerUPKernel/PPCRemPortList
- PowerUPKernel/PPCRemTail
- PowerUPKernel/PPCRemTailSync
- PowerUPKernel/PPCReplyMessage
- PowerUPKernel/PPCRevision
- PowerUPKernel/PPCSeek
- PowerUPKernel/PPCSendMessage
- PowerUPKernel/PPCSetPortListAttr
- PowerUPKernel/PPCSetSignal
- PowerUPKernel/PPCSetTaskAttr
- PowerUPKernel/PPCSetTimerObject
- PowerUPKernel/PPCSignal
- PowerUPKernel/PPCsprintf
- PowerUPKernel/PPCSub64
- PowerUPKernel/PPCSub64p
- PowerUPKernel/PPCUnLoadObject
- PowerUPKernel/PPCVersion
- PowerUPKernel/PPCvfprintf
- PowerUPKernel/PPCvkprintf
- PowerUPKernel/PPCvprintf
- PowerUPKernel/PPCvsprintf
- PowerUPKernel/PPCWait
- PowerUPKernel/PPCWaitPort
- PowerUPKernel/PPCWaitPortList
- PowerUPKernel/PPCWrite
- PowerUPKernel/PPCWriteByte
- PowerUPKernel/PPCWriteLong
- PowerUPKernel/PPCWriteWord
- PowerUPKernel/PPCXor64
- PowerUPKernel/PPCXor64p
- PowerUPKernel/PPCAdd64 PowerUPKernel/PPCAdd64
-
- NAME
- PPCAdd64 -- Add 2 64bit integers
-
- SYNOPSIS
- Result = PPCAdd64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCAdd64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Adds 2 64bit integers and returns the 64bit result in 2
- 32bit registers.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCAdd64p()
-
- PowerUPKernel/PPCAdd64p PowerUPKernel/PPCAdd64p
-
- NAME
- PPCAdd64p -- Add 2 64bit integers
-
- SYNOPSIS
- PPCAdd64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCAdd64p(long long*,long long*);
-
- FUNCTION
- Adds 2 64bit integers and returns the 64bit result in
- A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCAdd64()
-
- PowerUPKernel/PPCAddHead PowerUPKernel/PPCAddHead
-
- NAME
- PPCAddHead -- insert node at the head of a list
-
- SYNOPSIS
- PPCAddHead(list, node)
- gpr3 gpr4
-
- void PPCAddHead(struct List *, struct Node *)
-
- FUNCTION
- Add a node to the head of a doubly linked list.
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- list - a pointer to the target list header
- node - the node to insert at head
-
- SEE ALSO
- PPCAddTail(), PPCEnqueue(),
- PPCInsert(), PPCRemove(),
- PPCRemHead(), PPCRemTail()
-
- PowerUPKernel/PPCAddHeadSync PowerUPKernel/PPCAddHeadSync
-
- NAME
- PPCAddHeadSync -- sync insert node at the head of a list
-
- SYNOPSIS
- PPCAddHeadSync(list, node)
- gpr3 gpr4
-
- void PPCAddHeadSync(struct List *, struct Node *)
-
- FUNCTION
- Add a node to the head of a doubly linked list.
-
- INPUTS
- list - a pointer to the target list header
- node - the node to insert at head
-
- SEE ALSO
- PPCAddTailSync(), PPCEnqueueSync(),
- PPCInsertSync(), PPCRemoveSync(),
- PPCRemHeadSync(), PPCRemTailSync()
-
- PowerUPKernel/PPCAddPortList PowerUPKernel/PPCAddPortList
-
- NAME
- PPCAddPortList -- Add a port to the PPCPortList object
-
- SYNOPSIS
- Success = PPCAddPortList(PPCPortList,PPCPort)
- gpr3 gpr3 gpr4
-
- BOOL PPCAddPortList(void*,void*);
-
- FUNCTION
- This function adds a new Port to your PPCPortList object.
-
- INPUT
- PPCPortList - a pointer to the PPCPortList object
- PPCPort - a pointer to the PPC Message port
-
- RESULT
- Success - A Boolean tells you if the operation was successful.
-
- SEE ALSO
- PPCCreatePortList(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCAddTail PowerUPKernel/PPCAddTail
-
- NAME
- PPCAddTail -- append node to tail of a list
-
- SYNOPSIS
- PPCAddTail(list, node)
- gpr3 gpr4
-
- void PPCAddTail(struct List *, struct Node *);
-
- FUNCTION
- Add a node to the tail of a doubly linked list.
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- list - a pointer to the target list header
- node - a pointer to the node to insert at tail of the list
-
- SEE ALSO
- PPCAddHead(), PPCEnqueue(),
- PPCInsert(), PPCRemove(),
- PPCRemHead(), PPCRemTail()
-
- PowerUPKernel/PPCAddTailSync PowerUPKernel/PPCAddTailSync
-
- NAME
- PPCAddTailSync -- sync append node to tail of a list
-
- SYNOPSIS
- PPCAddTailSync(list, node)
- gpr3 gpr4
-
- void PPCAddTailSync(struct List *, struct Node *);
-
- FUNCTION
- Add a node to the tail of a doubly linked list.
-
- INPUTS
- list - a pointer to the target list header
- node - a pointer to the node to insert at tail of the list
-
- SEE ALSO
- PPCAddHeadSync(), PPCEnqueueSync(),
- PPCInsertSync(), PPCRemoveSync(),
- PPCRemHeadSync(), PPCRemTailSync()
-
- PowerUPKernel/PPCAllocMem PowerUPKernel/PPCAllocMem
-
- NAME
- PPCAllocMem -- Alloc a PPC cache aligned memory block
-
- SYNOPSIS
- Memory = PPCAllocMem(size,attributes )
- gpr3 gpr3 gpr4
-
- void *PPCAllocMem(ULONG,ULONG);
-
- FUNCTION
- Allocates a memoryblock which is aligned to the PPC cache lines.
- You should only use the PPC with memblocks allocated through
- this function.
-
- INPUTS
- Size - memory block size
- Attributes - memory attributes
-
- o exec/memory.h attributes
-
- o MEMF_NOCACHESYNCPPC for a synchronized non cacheable mapped
- memory area on the PPC side. The Amiga side is still copyback then.
- Synchronized means that accesses to that memory are in order
- for the CPU which is typically used for IO memory.
-
- o MEMF_NOCACHESYNCM68K for a synchronized non cacheable mapped
- memory area on the M68k side. The PPC side is still copyback then.
- Synchronized means that accesses to that memory are in order
- for the CPU which is typically used for IO memory.
-
- o MEMF_NOCACHEPPC for a nonsynchronized non cacheable mapped
- memory area on the PPC side. The Amiga side is still copyback then.
- Not Synchronized means that accesses to that memory may not be
- in order for the CPU which is typically used for framebuffer memory.
-
- o MEMF_NOCACHEM68K for a nosynchronized non cacheable mapped
- memory area on the M68k side. The PPC side is still copyback then.
- Not Synchronized means that accesses to that memory may not be
- in order for the CPU which is typically used for framebuffer memory.
-
- o MEMF_WRITETHROUGHPPC for writethrough mapped memory area on the
- PPC side. The 68k side is still copyback then.
- Writethrough means that the cache updates every write to the
- cache at once to the memory.
-
- o MEMF_WRITETHROUGH68K for writethrough mapped memory area on the
- 68k side. The PPC side is still copyback then.
- Writethrough means that the cache updates every write to the
- cache at once to the memory.
-
-
- If you use the M68k and PPC attribute at the same time the memory
- is mapped noncacheable on both sides. This also means that your
- allocation is 4096 Bytes aligned that may waste memory if you need
- less ram.
-
- RESULT
- Memory - ptr to the memory block
-
- NOTES
- The reason for this routine is that there's a serious
- cache copyback problem when ppc and 68060 cache lines
- cross borders. Then the contents of the memory isn't guranteed.
- The cache issue is explained in detail in Docs/PowerUP.guide
-
- SEE ALSO
- PPCFreeMem, exec/memory.h
-
- PowerUPKernel/PPCAllocPooled PowerUPKernel/PPCAllocPooled
-
- NAME
- PPCAllocPooled -- Allocate memory with the pool manager
-
- SYNOPSIS
- memory=PPCAllocPooled(poolHeader,memSize)
- gpr3 gpr3 gpr4
-
- void *PPCAllocPooled(void *,ULONG);
-
- FUNCTION
- Allocate memSize bytes of memory, and return a pointer. NULL is
- returned if the allocation fails.
-
- Doing a DeletePool() on the pool will free all of the puddles
- and thus all of the allocations done with AllocPooled() in that
- pool. (No need to FreePooled() each allocation)
-
- INPUTS
- memSize - the number of bytes to allocate
- poolHeader - a specific private pool header.
-
- RESULT
- A pointer to the memory, or NULL.
- The memory block returned is long word aligned.
-
- NOTES
- The pool function do not protect an individual pool from
- multiple accesses. The reason is that in most cases the pools
- will be used by a single task. If your pool is going to
- be used by more than one task you must Semaphore protect
- the pool from having more than one task trying to allocate
- within the same pool at the same time.
-
- SEE ALSO
- PPCFreePooled(), PPCCreatePool(), PPCDeletePool()
-
- PowerUPKernel/PPCAllocSignal PowerUPKernel/PPCAllocSignal
-
- NAME
- PPCAllocSignal -- allocate a PPC task signal bit
-
- SYNOPSIS
- signalNum = PPCAllocSignal(signalNum)
- gpr3 gpr3
-
- ULONG PPCAllocSignal(LONG);
-
- FUNCTION
- Allocate a signal bit from the current PPC task's free signals.
- Either a particular bit, or the next free bit may be allocated.
- The signal associated with the bit will be properly initialized
- (cleared).
- At least 16 user signals are available per task. Signals should
- be deallocated before the task exits.
-
- If the signal is already in use (or no free signals are available)
- a -1 is returned.
-
- Allocated signals are only valid for use with the task that
- allocated them.
-
-
- INPUTS
- signalNum - the desired signal number {of 0..31} or -1 for no
- preference.
-
- RESULTS
- signalNum - the signal bit number allocated {0..31}. If no signals
- are available, this function returns -1.
-
- SEE ALSO
- PPCFreeSignal()
-
- PowerUPKernel/PPCAllocVec PowerUPKernel/PPCAllocVec
-
- NAME
- PPCAllocVec -- allocate memory and keep track of the size (V36)
-
- SYNOPSIS
- memoryBlock = PPCAllocVec(byteSize, attributes)
- gpr3 gpr3 gpr4
-
- void *PPCAllocVec(ULONG, ULONG);
-
- INPUTS
- Size - memory block size
- Attributes - memory attributes
-
- o exec/memory.h attributes
-
- o MEMF_NOCACHESYNCPPC for a synchronized non cacheable mapped
- memory area on the PPC side. The Amiga side is still copyback then.
- Synchronized means that accesses to that memory are in order
- for the CPU which is typically used for IO memory.
-
- o MEMF_NOCACHESYNCM68K for a synchronized non cacheable mapped
- memory area on the M68k side. The PPC side is still copyback then.
- Synchronized means that accesses to that memory are in order
- for the CPU which is typically used for IO memory.
-
- o MEMF_NOCACHEPPC for a nonsynchronized non cacheable mapped
- memory area on the PPC side. The Amiga side is still copyback then.
- Not Synchronized means that accesses to that memory may not be
- in order for the CPU which is typically used for framebuffer memory.
-
- o MEMF_NOCACHEM68K for a nosynchronized non cacheable mapped
- memory area on the M68k side. The PPC side is still copyback then.
- Not Synchronized means that accesses to that memory may not be
- in order for the CPU which is typically used for framebuffer memory.
-
- o MEMF_WRITETHROUGHPPC for writethrough mapped memory area on the
- PPC side. The 68k side is still copyback then.
- Writethrough means that the cache updates every write to the
- cache at once to the memory.
-
- o MEMF_WRITETHROUGH68K for writethrough mapped memory area on the
- 68k side. The PPC side is still copyback then.
- Writethrough means that the cache updates every write to the
- cache at once to the memory.
-
- If you use the M68k and PPC attribute at the same time the memory
- is mapped noncacheable on both sides. This also means that your
- allocation is 4096 Bytes aligned that may waste memory if you need
- less ram.
-
- RESULT
- Memory - ptr to the memory block
-
- FUNCTION
- This function works identically to AllocMem(), but tracks the size
- of the allocation.
-
- See the PPCAllocMem() documentation for details.
-
- WARNING
- The result of any memory allocation MUST be checked, and a viable
- error handling path taken. ANY allocation may fail if memory has
- been filled.
- The cache issue is explained in detail in Docs/PowerUP.guide
-
- SEE ALSO
- PPCFreeVec(), PPCAllocMem()
-
- PowerUPKernel/PPCAllocVecPooled PowerUPKernel/PPCAllocVecPooled
-
- NAME
- PPCAllocVecPooled -- allocate memory with the pool manager and keep track of
- the size
-
- SYNOPSIS
- memoryBlock = PPCAllocVecPooled(Pool,byteSize)
- gpr3 gpr3 gpr4
-
- void *PPCAllocVecPooled(void*, ULONG);
-
- FUNCTION
- This function works identically to PPCAllocPooled(), but tracks the size
- of the allocation.
-
- See the PPCAllocMem() documentation for details.
-
- SEE ALSO
- PPCFreeVecPooled(), exec/memory.h, ppclib/memory.h
-
- PowerUPKernel/PPCAnd64 PowerUPKernel/PPCAnd64
-
- NAME
- PPCAnd64 -- And 2 64 bit integer values (V46)
-
- SYNOPSIS
- Value = PPCAnd64(ValueA , ValueB)
- gpr3:gpr4 gpr3:gpr4 gpr5:gpr6
-
- long long PPCAnd64(long long, long long);
-
- FUNCTION
- Ands 2 long long values and returns a long long result.
-
- INPUTS
- ValueA - long long value A
- ValueB - long long value B
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCAnd64p()
-
- PowerUPKernel/PPCAnd64p PowerUPKernel/PPCAnd64p
-
- NAME
- PPCAnd64p -- And 2 64 bit integer values (V46)
-
- SYNOPSIS
- PPCAnd64p(ValuePtrA, ValuePtrB)
- gpr3 gpr4
-
- void PPCAnd64p(long*,long*);
-
- FUNCTION
- Ands 2 long long values and returns the result at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ValuePtrB - ptr to a long long value B
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCAnd64()
-
- PowerUPKernel/PPCAsl64 PowerUPKernel/PPCAsl64
-
- NAME
- PPCAsl64 -- Arithmetic Shift left an 64 bit integer (V46)
-
- SYNOPSIS
- Value = PPCAsl64(ValueA , ShiftOffset)
- gpr3:gpr4 gpr3:gpr4 gpr5
-
- long long PPCAsl64(long long, int);
-
- FUNCTION
- Arithmetic shift left a long long value and return a long long result.
-
- INPUTS
- ValueA - long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCAsl64p()
-
- PowerUPKernel/PPCAsl64p PowerUPKernel/PPCAsl64p
-
- NAME
- PPCAsl64p -- Arithmetic Shift left an 64 bit integer (V46)
-
- SYNOPSIS
- PPCAsl64p(ValuePtrA, Shiftoffset)
- gpr3 gpr4
-
- void PPCAsl64p(long*,int);
-
- FUNCTION
- Arithmetic shift left a long long value and return at return
- at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCAsl64()
-
- PowerUPKernel/PPCAsr64 PowerUPKernel/PPCAsr64
-
- NAME
- PPCAsr64 -- Arithmetic Shift right an 64 bit integer (V46)
-
- SYNOPSIS
- Value = PPCAsr64(ValueA , ShiftOffset)
- gpr3:gpr4 gpr3:gpr4 gpr5
-
- long long PPCAsr64(long long, int);
-
- FUNCTION
- Arithmetic shift right a long long value and return a long long result.
-
- INPUTS
- ValueA - long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCAsr64p()
-
- PowerUPKernel/PPCAsr64p PowerUPKernel/PPCAsr64p
-
- NAME
- PPCAsr64p -- Arithmetic Shift right an 64 bit integer (V46)
-
- SYNOPSIS
- PPCAsr64p(ValuePtrA, Shiftoffset)
- gpr3 gpr4
-
- void PPCAsr64p(long*,int);
-
- FUNCTION
- Arithmetic shift right a long long value and return at return
- at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCAsr64()
-
- PowerUPKernel/PPCAttemptSemaphore PowerUPKernel/PPCAttemptSemaphore
-
- NAME
- PPCAttemptSemaphore -- try to obtain without blocking
-
- SYNOPSIS
- success = PPCAttemptSemaphore(Semaphore)
- gpr3 gpr3
-
- LONG PPCAttemptSemaphore(void*);
-
- FUNCTION
- This call is similar to PPCObtainSemaphore(), except that it will not
- block if the semaphore could not be locked.
-
- INPUT
- Semaphore -- a semaphore object returned by PPCCreateSemaphore()
-
- RESULT
- success -- TRUE if the semaphore was locked, false if some
- other task already possessed the semaphore.
-
- SEE ALSO
- PPCObtainSemaphoreShared(), PPCObtainSemaphoreByName(),
- PPCReleaseSemaphore(), PPCAttemptSemaphoreShared(),
- PPCAttemptSemaphoreByName()
-
- PowerUPKernel/PPCAttemptSemaphoreByNameowerUPKernel/PPCAttemptSemaphoreByName
-
- NAME
- PPCAttemptSemaphoreByName -- try to obtain without blocking
-
- SYNOPSIS
- Semaphore PPCAttemptSemaphoreByName(Name,Error)
- gpr3 gpr4
-
- void* PPCAttemptSemaphoreByName(char *,ULONG *)
-
- FUNCTION
- Tries to find a Semaphore by the name and does an PPCAttemptSemaphore().
- No Arbitration needed.
- If it succeeds the Result is TRUE and if doesn't find it
- it returns the error reason at the address you given as
- the ErrorPtr.
- Current ErrorCodes are PPCSEMAPHOREERROR_SEMAPHORENOTFOUND or
- PPCSEMAPHOREERROR_OBTAINED when the attempt hadn't succeed.
-
- INPUTS
- Name - Ptr to the name cstring
- Error - Ptr to an error result field
-
-
- RESULTS
- Semaphore - If FALSE no Semaphore with that name was found
-
- SEE ALSO
- PPCAttemptSemaphore(), PPCObtainSemaphoreByName()
-
- PowerUPKernel/PPCAttemptSemaphoreSharedowerUPKernel/PPCAttemptSemaphoreShared
-
- NAME
- PPCAttemptSemaphoreShared -- try to obtain without blocking
-
- SYNOPSIS
- success = PPCAttemptSemaphoreShared(Semaphore)
- gpr3 gpr3
-
- BOOL PPCAttemptSemaphoreShared(void*);
-
- FUNCTION
- This call is similar to PPCObtainSemaphoreShared(), except that it
- will not block if the semaphore could not be locked.
-
- INPUT
- Semaphore -- a semaphore object returned by PPCCreateSemaphore()
-
- RESULT
- success -- TRUE if the semaphore was granted, false if some
- other task already possessed the semaphore in
- exclusive mode.
-
- SEE ALSO
- PPCObtainSemaphoreShared(), PPCObtainSemaphoreByName(),
- PPCReleaseSemaphore(), PPCAttemptSemaphore(),
- PPCAttemptSemaphoreByName()
-
- PowerUPKernel/PPCCacheFlush PowerUPKernel/PPCCacheFlush
-
- NAME
- PPCCacheFlush - User callable custom cache clearing
-
- SYNOPSIS
- PPCCacheFlush(Address,Length)
- gpr3 gpr4
-
- void PPCCacheFlush(APTR,ULONG);
-
- FUNCTION
- Flush out the contents of the instruction and Data PPC cache in
- a certain address space. Useful to optimize the shared memory
- handling because flushing the whole cache may not what you
- want.
- If dirty data cache lines are present, push them to memory first.
-
- Caches must be cleared after *any* operation that could cause
- invalid or stale data. The most common cases are DMA,modifying
- instructions using the processor or modifying Data which is
- shared by the 680xx and PPC.
-
- ATTENTION
- Please read the PowerUP.guide Cache chapter before you use
- this function.
-
- SEE ALSO
- PPCCacheFlushAll(), PPCCacheInvalid()
-
- PowerUPKernel/PPCCacheFlushAll PowerUPKernel/PPCCacheFlushAll
-
- NAME
- PPCCacheFlushAll - User callable simple cache clearing
-
- SYNOPSIS
- PPCCacheFlushAll()
-
- void PPCCacheFlushAll(void);
-
- FUNCTION
- Flush out the contents of the instruction and Data PPC cache.
- If dirty data cache lines are present, push them to memory first.
-
- Caches must be cleared after *any* operation that could cause
- invalid or stale data. The most common cases are DMA,modifying
- instructions using the processor or modifying Data which is
- shared by the 680xx and PPC.
-
- ATTENTION
- Please read the PowerUP.guide Cache chapter before you use
- this function.
-
- SEE ALSO
- PPCCacheFlush(), PPCCacheInvalid()
-
- PowerUPKernel/PPCCacheInvalid PowerUPKernel/PPCCacheInvalid
-
- NAME
- PPCCacheInvalid - User callable custom cache invalidating
-
- SYNOPSIS
- PPCCacheInvalid(Address,Length)
- gpr3 gpr4
-
- void PPCCacheInvalid(APTR,ULONG);
-
- FUNCTION
- Invalid the contents of the instruction and Data PPC cache in
- a certain address space. Useful to optimize the shared memory
- handling because flushing the whole cache may not what you
- want. This function doesn`t write back the contents of the used
- dirty cache lines.
- Be also aware that the Address must be PPC cache line aligned,
- to avoid that you invalid cache lines you partly use.
-
- ATTENTION
- Please read the PowerUP.guide Cache chapter before you use
- this function.
-
- SEE ALSO
- PPCCacheFlushAll(), PPCCacheFlush()
-
- PowerUPKernel/PPCCallM68k PowerUPKernel/PPCCallM68k
-
- NAME
- PPCCallM68k -- Calls a M68k Function
-
- SYNOPSIS
- PPCCallM68k(Caos)
- gpr3
-
- ULONG PPCCallM68k(struct Caos*);
-
- FUNCTION
- Calls a m68k function and returns the result. You have
- to be very careful with what the function does.
-
- INPUTS
- Caos - The lib,offset,register structure
-
- EXAMPLE
- Caos.caos_Un.Function - needs the function address
- Caos.d0-a6 - take the parameters
-
- NOTE
- This function won`t be supported by a recompile
- for the ABox OS. It may only run in an AmigaOS
- emulation.
-
- DESCRIPTION
- For calling functions from the PPC under M68k AmigaOS or for
- calling functions on the PPC Supervisor mode you have to care
- for the cache issues. Please read the Cache chapter in the
- docs/powerup.guide about the cache problems involved.
- If you do something wrong here you can expect that you loose
- data, get wrong data or simply crash the machine.
- The caos register fields are updated with the register values
- when the M68k function exits.(V45)
-
- IF_CACHEFLUSHNO:
- You use this mode for the cpu if your function
- touches no memory both cpus use.
-
- Example: Close(File)
- If you call this function by the PPC there`s no need
- to flush the cache because the PPC isn`t allowed to
- touch any memory which has to do with the File BPTR.
- ATTENTION:
- The PPC MUST NOT be used to poke into AmigaOS system
- structures.
-
- IF_CACHEFLUSHALL:
- You use this mode for the cpu if your function
- touches memory both cpus use and it`s no simple memory area
- which may be flushed individually. This should be used by default.
-
- Example: OpenWindowTagList(NewWindow,TagList)
- Here you pass a complex data structure which may use
- memory areas at several different areas.
-
- IF_CACHEFLUSHAREA:
- You use this mode for the cpu if your function
- touches memory both cpus use and it`s a memory area which isn`t
- very big. It depends on the size and how many lines are dirty
- if this is faster than IF_CACHEFLUSHALL.
- With the Start and Length fields of each cpu you can define
- the area.
-
- Example: Write(File,Address,Length)
- When the PPC runs this function the PPC must make sure
- that all data in the to be written memory area is in
- in the memory and not only in the cache.
-
- IF_CACHEINVALIDAREA: (V45)
- You use this mode for the cpu if your function
- touches memory both cpus use and it`s a memory area where you
- don`t care for valid data anymore.
- With the Start and Length fields of each cpu you can define
- the area.
-
- Example: Read(File,Address,Length)
- When the PPC runs this function the PPC has no need
- anymore for anything which is in its cache for the
- area the Address and Length define, so you could
- invalidate this instead of doing a cacheflush which
- may write back dirty lines.
- Be VERY careful about this.
-
- ATTENTION! The Address must be 32Byte aligned, so you should always
- use PPCAllocMem for data which is used on the M68k and PPC
- You are NOT allowed to use normal pools for exchanging data between
- the M68k and PPC.
-
- IF_ASYNC: (V45)
- If you use this flag, the function is called asynchronous and
- the PPC doesn`t have to wait for a result.
- This flag is only checked in the M68kCacheMode field.
- This also means that the result of the PPCCall#? function
- is meaningless.
- Normally this flag doesn`t really fit into a CacheMode flag, but
- well..too bad i haven`t declared another flag field there.
-
- SEE ALSO
- PPCCallOS()
-
- PowerUPKernel/PPCCallOS PowerUPKernel/PPCCallOS
-
- NAME
- PPCCallOS -- Calls an OS Library Function
-
- SYNOPSIS
- PPCCallOS(Caos)
- gpr3
-
- ULONG PPCCallOS(struct Caos*);
-
- FUNCTION
- Calls an OS function and returns the result. You have
- to be very careful which function you call. With
- FD2Inline you can create all inline AmigaOS inline calls.
-
- INPUTS
- Caos - The lib,offset,register structure
-
- EXAMPLE
- PPCAllocMem(Size,Attribute):
- Caos.caos_Un.Offset = LVO_AllocMem;
- Caos.d0 = Size;
- Caos.d1 = Attribute;
- Caos.a6 = SysBase;
-
- NOTE
- This function isn`t source portable to the next
- OS. It may only run in an AmigaOS emulation.
-
- DESCRIPTION
- For calling functions from the PPC under M68k AmigaOS or for
- calling functions on the PPC Supervisor mode you have to care
- for the cache issues. Please read the Cache chapter in the
- docs/powerup.guide about the cache problems involved.
- If you do something wrong here you can expect that you loose
- data, get wrong data or simply crash the machine.
-
- IF_CACHEFLUSHNO:
- You use this mode for the cpu if your function
- touches no memory both cpus use.
-
- Example: Close(File)
- If you call this function by the PPC there`s no need
- to flush the cache because the PPC isn`t allowed to
- touch any memory which has to do with the File BPTR.
- ATTENTION:
- The PPC MUST NOT be used to poke into AmigaOS system
- structures.
-
- IF_CACHEFLUSHALL:
- You use this mode for the cpu if your function
- touches memory both cpus use and it`s no simple memory area
- which may be flushed individually. This should be used by default.
-
- Example: OpenWindowTagList(NewWindow,TagList)
- Here you pass a complex data structure which may use
- memory areas at several different areas.
-
- IF_CACHEFLUSHAREA:
- You use this mode for the cpu if your function
- touches memory both cpus use and it`s a memory area which isn`t
- very big. It depends on the size and how many lines are dirty
- if this is faster than IF_CACHEFLUSHALL.
- With the Start and Length fields of each cpu you can define
- the area.
-
- Example: Write(File,Address,Length)
- When the PPC runs this function the PPC must make sure
- that all data in the to be written memory area is in
- in the memory and not only in the cache.
-
- IF_CACHEINVALIDAREA: (V45)
- You use this mode for the cpu if your function
- touches memory both cpus use and it`s a memory area where you
- don`t care for valid data anymore.
- With the Start and Length fields of each cpu you can define
- the area.
-
- Example: Read(File,Address,Length)
- When the PPC runs this function the PPC has no need
- anymore for anything which is in its cache for the
- area the Address and Length define, so you could
- invalidate this instead of doing a cacheflush which
- may write back dirty lines.
- Be VERY careful about this.
-
- ATTENTION! The Address must be 32Byte aligned, so you should always
- use PPCAllocMem for data which is used on the M68k and PPC
- You are NOT allowed to use normal pools for exchanging data between
- the M68k and PPC.
-
- IF_ASYNC: (V45)
- If you use this flag, the function is called asynchronous and
- the PPC doesn`t have to wait for a result.
- This flag is only checked in the M68kCacheMode field.
- This also means that the result of the PPCCall#? function
- is meaningless.
- Normally this flag doesn`t really fit into a CacheMode flag, but
- well..too bad i haven`t declared another flag field there.
-
- SEE ALSO
- PPCCallM68k()
-
- PowerUPKernel/PPCClose PowerUPKernel/PPCClose
-
- NAME
- PPCClose -- Close an open file
-
- SYNOPSIS
- success = PPCClose( file )
- gpr3 gpr3
-
- BOOL PPCClose(BPTR)
-
- FUNCTION
- This function is equal to the dos.library/Close function.
- It works in the context of the Msg Task each PPC Task has
- on the AmigaOS side.
-
- INPUTS
- file - BCPL pointer to a file handle
-
- RESULTS
- success - returns if PPCClose() succeeded.
-
- SEE ALSO
- PPCOpen(), PPCRead(), PPCWrite(), PPCSeek()
-
- PowerUPKernel/PPCCloseLibrary PowerUPKernel/PPCCloseLibrary
-
- NAME
- PPCCloseLibrary -- Close a shared object module (V46)
-
- SYNOPSIS
- PPCCloseLibrary(LibObject)
-
- void PPCCloseLibrary(void*);
- gpr3
-
- FUNCTION
- Closes a shared elf object. If the object isn`t used
- anymore and if the function __LIB_Expunge exists it is
- executed and if it returns TRUE the shared object is
- removed.
-
- INPUTS
- LibObject - shared library object
-
- RESULT
-
- NOTES
- Simular to the NetBSD dlopen(), dlclose(), dlsym() interface.
- If there`s a working ld a dynamic symbol link shouldn`t be
- the problem anymore but at the moment LD isn`t useful.
-
- SEE ALSO
- PPCOpenLibrary(), PPCGetLibSymbol()
-
- PowerUPKernel/PPCCmp64 PowerUPKernel/PPCCmp64
-
- NAME
- PPCCmp64 -- Compare 2 64bit integers
-
- SYNOPSIS
- Result = PPCCmp64(highA,lowA,highB,lowB )
- gpr3 gpr3 gpr4 gpr5 gpr6
-
- int PPCCmp64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Compares 2 64bit integers and returns the state of
- the comparision.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 0 A=B
- +1 A>B
- -1 A<B
- SEE ALSO
- PPCCmp64p()
-
- PowerUPKernel/PPCCmp64p PowerUPKernel/PPCCmp64p
-
- NAME
- PPCCmp64p -- Compare 2 64bit integers
-
- SYNOPSIS
- Result = PPCCmp64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- LONG PPCCmp64p(long long*,long long*);
-
- FUNCTION
- Compares 2 64bit integers and returns the state of
- the comparision.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- RESULT
- Result - 0 A=B
- +1 A>B
- -1 A<B
-
- SEE ALSO
- PPCCmp64()
-
- PowerUPKernel/PPCCoerceMethodA PowerUPKernel/PPCCoerceMethodA
-
- NAME
- PPCCoerceMethodA -- Perform method on coerced object.
-
- SYNOPSIS
- result = PPCCoerceMethodA( cl, obj, msg )
-
- ULONG PPCCoerceMethodA( struct IClass *, Object *, Msg );
-
- FUNCTION
- Boopsi support function that invokes the supplied message
- on the specified object, as though it were the specified
- class.
-
- INPUTS
- cl - pointer to boopsi class to receive the message
- obj - pointer to boopsi object
- msg - pointer to method-specific message to send
-
- RESULT
- result - class and message-specific result.
-
- NOTES
- This function is not source portable.
-
- SEE ALSO
- PPCDoMethodA(), PPCDoSuperMethodA(), <intuition/classusr.h>
- ROM Kernel Manual boopsi section
-
- PowerUPKernel/PPCCreateMessage PowerUPKernel/PPCCreateMessage
-
- NAME
- PPCCreateMessage -- Create a Message for a PPCMsgPort
-
- SYNOPSIS
- Message = PPCCreateMessage(PPCPort,Length)
- gpr3 gpr3 gpr4
-
- void* PPCCreateMessage(void*,ULONG);
-
- FUNCTION
- Creates a Message for PPCPort communication.
- The Length parameter may be useful in the future to optimize
- messages in certain addressspace mappings for IPC in a MP system.
- It isn`t necessary to specify a Length which is > max(DataSize)
- but it may result in a performance win in the future.
- A message and msgdata can`t be reused or touched after a SendMessage
- until the message was replied.
-
- INPUTS
- PPCPort - Ptr to an object generated by PPCCreatePort
- Length - Max Length for Messages
-
- RESULT
- PPCMessage - PPCMessage Object ptr.
-
- SEE ALSO
- PPCDeleteMessage(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCCreatePool PowerUPKernel/PPCCreatePool
-
- NAME
- PPCCreatePool -- Generate a private memory pool header
-
- SYNOPSIS
- newPool=PPCCreatePool(memFlags,puddleSize,threshSize)
- gpr3 gpr3 gpr4 gpr5
-
- void *PPCCreatePool(ULONG,ULONG,ULONG);
-
- FUNCTION
- Allocate and prepare a new memory pool header. Each pool is a
- separate tracking system for memory of a specific type. Any number
- of pools may exist in the system.
-
- Pools automatically expand and shrink based on demand. Fixed sized
- "puddles" are allocated by the pool manager when more total memory
- is needed. Many small allocations can fit in a single puddle.
- Allocations larger than the threshSize are allocation in their own
- puddles.
-
- At any time individual allocations may be freed. Or, the entire
- pool may be removed in a single step.
-
- INPUTS
- memFlags - a memory flags specifier, as taken by AllocMem.
-
- o exec/memory.h attributes
-
- o MEMF_NOCACHESYNCPPC for a synchronized non cacheable mapped
- memory area on the PPC side. The Amiga side is still copyback then.
- Synchronized means that accesses to that memory are in order
- for the CPU which is typically used for IO memory.
-
- o MEMF_NOCACHESYNCM68K for a synchronized non cacheable mapped
- memory area on the M68k side. The PPC side is still copyback then.
- Synchronized means that accesses to that memory are in order
- for the CPU which is typically used for IO memory.
-
- o MEMF_NOCACHEPPC for a nonsynchronized non cacheable mapped
- memory area on the PPC side. The Amiga side is still copyback then.
- Not Synchronized means that accesses to that memory may not be
- in order for the CPU which is typically used for framebuffer memory.
-
- o MEMF_NOCACHEM68K for a nosynchronized non cacheable mapped
- memory area on the M68k side. The PPC side is still copyback then.
- Not Synchronized means that accesses to that memory may not be
- in order for the CPU which is typically used for framebuffer memory.
-
- o MEMF_WRITETHROUGHPPC for writethrough mapped memory area on the
- PPC side. The 68k side is still copyback then.
- Writethrough means that the cache updates every write to the
- cache at once to the memory.
-
- o MEMF_WRITETHROUGH68K for writethrough mapped memory area on the
- 68k side. The PPC side is still copyback then.
- Writethrough means that the cache updates every write to the
- cache at once to the memory.
-
- If you use the M68k and PPC attribute at the same time the memory
- is mapped noncacheable on both sides. This also means that your
- allocation is 4096 Bytes aligned that may waste memory if you need
- less ram.
-
- puddleSize - the size of Puddles...
- threshSize - the largest allocation that goes into normal puddles
- This *MUST* be less than or equal to puddleSize
- (CreatePool() will fail if it is not)
-
- RESULT
- The address of a new pool header, or NULL for error.
-
- SEE ALSO
- PPCDeletePool(), PPCAllocPooled(), PPCFreePooled(), exec/memory.i
-
- PowerUPKernel/PPCCreatePort PowerUPKernel/PPCCreatePort
-
- NAME
- PPCCreatePort -- Create a PPC Message Port
-
- SYNOPSIS
- Port = PPCCreatePort(Tags)
- gpr3 gpr3
-
- void* PPCCreatePort(struct TagItem*);
-
- FUNCTION
- Creates a local PPC MsgPort to receive messages from the PPC.
- With a specified name you can mark it public to the ppc.library.
- This shouldn`t be missunderstood as a public system port because
- PPCPorts and Amigaports are different entities.
-
- INPUTS
- Tags - Tags to specify a public port for example.
-
- o PPCPORTTAG_NAME,"Name"
- defines the name of a public PPC port.
-
- o PPCPORTTAG_ERROR,(ULONG*) ErrorPtr
- defines the ptr for a more precise return error result
-
- RESULT
- Port - the PPCPort object or NULL
-
- SEE ALSO
- PPCDeletePort(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCCreatePortList PowerUPKernel/PPCCreatePortList
-
- NAME
- PPCCreatePortList -- Create a List of Ports to wait for
-
- SYNOPSIS
- PPCPortList = PPCCreatePortList(PPCPortArray,ExtSignals)
- gpr3 gpr3 gpr4
-
- void* PPCCreatePortList(void**,ULONG);
-
- FUNCTION
- This function creates a multi PPCPort object you can
- use to wait for several ports at once.
- If necessary, the Wait function will be called to wait for
- the port signal. If a message is already present at the
- port, this function will return immediately. The return
- value is always a pointer to the first PPC Message queued (but
- it is not removed from the queue.
-
- INPUT
- PPCPortArray - a pointer to a PPC Message port array..NULL terminated
- ExtSignals - mask of extended signals you wanna wait for
- additionally to the PPCPorts.
-
- RESULT
- PPCMessage - a pointer to the first available PPC Message or NULL.
-
- SEE ALSO
- PPCGetMessage(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCCreateSemaphore PowerUPKernel/PPCCreateSemaphore
-
- NAME
- PPCCreateSemaphore -- create a semaphore object
-
- SYNOPSIS
- PPCCreateSemaphore(Tags)
- gpr3
-
- void* PPCCreateSemaphoreA(struct TagItem *Tags)
-
- FUNCTION
- creates a Semaphore object for the usage with the semaphore functions.
-
- INPUTS
- MyTags - Here you have to specify all needed Tags.
-
-
- RESULTS
- Semaphore - If NULL the error code is available through the
- SEMAPHORETAG_ERROR
-
-
- SEE ALSO
- PPCObtainSemaphore(), PPCObtainSemaphoreByName(),
- PPCReleaseSemaphore(), PPCObtainSemaphoreShared(),
- PPCAttemptSemaphore(), PPCAttemptSemaphoreByName()
-
- PowerUPKernel/PPCCreateTask PowerUPKernel/PPCCreateTask
-
- NAME
- PPCCreateTask -- Create a PPC Task
-
- SYNOPSIS
- TaskObject = PPCCreateTask( ElfObject, PC , Tags )
- gpr3 gpr3 gpr4 gpr5
-
- void *PPCCreateTask(void*,void*,struct TagItem*);
-
- FUNCTION
- Creates an asynchron PPCTask with the given ElfObject
- and an optional code start. It works like the 68k
- ppc.library equivalent.
-
- Please check that autodocs entry for the tag
- description.
-
- INPUTS
- ElfObject - ElfObject created by PPCLoadObject
- PC - optional task start or NULL for normal
- ElfObject start.
- Tags - Tags to specify a the PPCTasks attributes
-
- NOTE
- The TAG PPCTASKTAG_WAITFINISH if FALSE all the time so
- you can only create asynchron ppc tasks.
-
- SEE ALSO
- ppc.library/PPCCreateTask(), powerup/ppclib/tasks.h
-
- PowerUPKernel/PPCCreateTimerObject PowerUPKernel/PPCCreateTimerObject
-
- NAME
- PPCCreateTimerObject -- create a TimerObject
-
- SYNOPSIS
- TimerObject = PPCCreateTimerObject(Tags);
- gpr3 gpr3
-
- void* PPCCreateTimerObject(struct TagItem*);
-
- FUNCTION
-
- INPUT
- Tag -- attribute
- o PPCTIMERTAG_CPU, BOOLEAN
- create a passive CPU tick object which you can only use
- to measure times between an event A and an event B.
-
- o PPCTIMERTAG_50HZ, Ticks
- create a notify timer job which notifies your task
- after 50Hz * Tick count.
-
- o PPCTIMERTAG_AUTOREMOVE, BOOLEAN
- to specify if the notify timer job is removed after the
- time ran down or if it should always run.
-
- o PPCTIMERTAG_SIGNALMASK, SignalMask
- the signal mask for PPCSignalTask() your task.
- Necessary if you wanna receive notify signals.
-
- ValuePtr -- Ptr to an unsigned long long or ULONG[2] where
- some optional value result. Not yet used.
-
- RESULT
- TimerObject -- a timerobject dependent on the tags
-
- SEE ALSO
- PPCDeleteTimerObject(), PPCGetTimerObject(), PPCSetTimerObject()
-
- PowerUPKernel/PPCDeleteMessage PowerUPKernel/PPCDeleteMessage
-
- NAME
- PPCDeleteMessage -- Delete a PPC Message
-
- SYNOPSIS
- PPCDeleteMessage(PPCMessage)
- gpr3
-
- void PPCDeleteMessage(void*);
-
- FUNCTION
- Deletes a PPC Message. You can only delete a msg your
- task allocated and which has already been replied or not
- send out.
-
- INPUTS
- PPCMessage - Ptr to an object generated by PPCCreateMessage
-
- SEE ALSO
- PPCCreatePort(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCDeletePool PowerUPKernel/PPCDeletePool
-
- NAME
- PPCDeletePool -- Drain an entire memory pool
-
- SYNOPSIS
- PPCDeletePool(poolHeader)
- gpr3
-
- void PPCDeletePool(void *);
-
- FUNCTION
- Frees all memory in all pudles of the specified pool header, then
- deletes the pool header. Individual free calls are not needed.
-
- INPUTS
- poolHeader - as returned by CreatePool().
-
- SEE ALSO
- PPCCreatePool(), PPCAllocPooled(), PPCFreePooled()
-
- PowerUPKernel/PPCDeletePort PowerUPKernel/PPCDeletePort
-
- NAME
- PPCDeletePort -- Delete a PPC Message Port
-
- SYNOPSIS
- Success = PPCDeletePort(PPCPort)
- gpr3 gpr3
-
- BOOL PPCDeletePort(void*);
-
- FUNCTION
- Deletes a local PPC MsgPort when the Port isn`t obtained
- by somebody else. If it`s obtained it returns FALSE so
- you have to decide yourself how you wanna recover this
- problem which maybe caused by a synchronizing problem
- between your M68k and PPC applications
-
- INPUTS
- PPCPort - PPCPort object generated by PPCCreatePort
-
- SEE ALSO
- PPCCreatePort(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCDeletePortList PowerUPKernel/PPCDeletePortList
-
- NAME
- PPCDeletePortList -- Deletes a PortList object
-
- SYNOPSIS
- PPCDeletePortList(PPCPortList)
- gpr3
-
- BOOL PPCDeletePortList(void*);
-
- FUNCTION
- This function deletes the PPCPortList object.
-
- INPUT
- PPCPortList - a pointer to the PPCPortList object
-
- RESULT
- Success - A Boolean tells you if the operation was successful.
-
- SEE ALSO
- PPCCreatePortList(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCDeleteSemaphore PowerUPKernel/PPCDeleteSemaphore
-
- NAME
- PPCDeleteSemaphore -- delete Semaphore
-
- SYNOPSIS
- PPCDeleteSemaphore(Semaphore)
- gpr3
-
- void PPCDeleteSemaphore(void*)
-
- FUNCTION
- deletes a Semaphore. If it can't delete it because
- of a remaining a PPCObtainSemaphore, the semaphore
- is deleted afterwards.
-
- INPUTS
- Semaphore -- a semaphore object returned by PPCCreateSemaphore()
-
- SEE ALSO
- PPCCreateSemaphore()
-
- PowerUPKernel/PPCDeleteTimerObject PowerUPKernel/PPCDeleteTimerObject
-
- NAME
- PPCDeleteTimerObject -- delete a TimerObject
-
- SYNOPSIS
- PPCDeleteTimerObject(TimerObject);
- gpr3
-
- void PPCDeleteTimerObject(void*);
-
- FUNCTION
- Delete the TimerObject.
-
- INPUT
- TimerObject -- object to be deleted.
-
- SEE ALSO
- PPCCreateTimerObject(), PPCGetTimerObject(), PPCSetTimerObject()
-
- PowerUPKernel/PPCDivRem64 PowerUPKernel/PPCDivRem64
-
- NAME
- PPCDivRem64 -- Div+Mod 2 64 bit integer values (V46)
-
- SYNOPSIS
- Value = PPCDivRem64(ValueA , ValueB, ModResultPtr)
- gpr3:gpr4 gpr3:gpr4 gpr5:gpr6 gpr7
-
- long long PPCDivRem64(long long, long long,long long*);
-
- FUNCTION
- Devide 2 long long values, return a long long result and
- return the modulu result at the ModResultPtr`s address.
-
- INPUTS
- ValueA - long long value A
- ValueB - long long value B
- ModResultPtr - ptr to the modulo result or NULL
-
- RESULT
- Value - long long result
- ModResultPtr - ptr to the modulo result or NULL
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCDivRem64p()
-
- PowerUPKernel/PPCDivRem64p PowerUPKernel/PPCDivRem64p
-
- NAME
- PPCDivRem64p -- DivRem 2 64 bit integer values (V46)
-
- SYNOPSIS
- PPCDivRem64p(ValuePtrA, ValuePtrB, ModResultPtr)
- gpr3 gpr4 gpr7
-
- void PPCDivRem64p(long*,long*,long*);
-
- FUNCTION
- Devide 2 long long values, returns the result at ValuePtrA
- and the modulu at the ModResultPtr`s address.
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ValuePtrB - ptr to a long long value B
- ModResultPtr - ptr to the modulo result or NULL
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
- ModResultPtr - ptr to the modulo result or NULL
-
- SEE ALSO
- PPCDivRem64()
-
- PowerUPKernel/PPCDivs64 PowerUPKernel/PPCDivs64
-
- NAME
- PPCDivs64 -- Divide 2 signed 64bit integers
-
- SYNOPSIS
- Result = PPCDivs64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCDivs64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Multiplies 2 signed 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCDivs64p()
-
- PowerUPKernel/PPCDivs64p PowerUPKernel/PPCDivs64p
-
- NAME
- PPCDivs64p -- Divide 2 signed 64bit integers
-
- SYNOPSIS
- PPCDivs64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCDivs64p(long long*,long long*);
-
- FUNCTION
- Multiplies 2 signed 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCDivs64()
-
- PowerUPKernel/PPCDivu64 PowerUPKernel/PPCDivu64
-
- NAME
- PPCDivu64 -- Divide 2 unsigned 64bit integers
-
- SYNOPSIS
- Result = PPCDivu64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCDivu64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Multiplies 2 unsigned 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCDivu64p()
-
- PowerUPKernel/PPCDivu64p PowerUPKernel/PPCDivu64p
-
- NAME
- PPCDivu64p -- Divide 2 unsigned 64bit integers
-
- SYNOPSIS
- PPCDivu64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCDivu64p(long long*,long long*);
-
- FUNCTION
- Multiplies 2 unsigned 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCDivu64()
-
- PowerUPKernel/PPCDoMethodA PowerUPKernel/PPCDoMethodA
-
- NAME
- PPCDoMethodA -- Perform method on object.
-
- SYNOPSIS
- result = PPCDoMethodA( obj, msg )
-
- ULONG PPCDoMethodA( Object *, Msg );
-
- FUNCTION
- Boopsi support function that invokes the supplied message
- on the specified object. The message is invoked on the
- object's true class.
-
- INPUTS
- obj - pointer to boopsi object
- msg - pointer to method-specific message to send
-
- RESULT
- result - specific to the message and the object's class.
-
- NOTES
- This function is not source portable.
-
- SEE ALSO
- PPCCoerceMethodA(), PPCDoSuperMethodA(), <intuition/classusr.h>
- ROM Kernel Manual boopsi section
-
- PowerUPKernel/PPCDoSuperMethodA PowerUPKernel/PPCDoSuperMethodA
-
- NAME
- PPCDoSuperMethodA -- Perform method on object coerced to superclass.
-
- SYNOPSIS
- result = PPCDoSuperMethodA( cl, obj, msg )
-
- ULONG PPCDoSuperMethodA( struct IClass *, Object *, Msg );
-
- FUNCTION
- Boopsi support function that invokes the supplied message
- on the specified object, as though it were the superclass
- of the specified class.
-
- INPUTS
- cl - pointer to boopsi class whose superclass is to
- receive the message
- obj - pointer to boopsi object
- msg - pointer to method-specific message to send
-
- RESULT
- result - class and message-specific result.
-
- NOTES
- This function is not source portable.
-
- SEE ALSO
- PPCCoerceMethodA(), PPCDoMethodA(), <intuition/classusr.h>
- ROM Kernel Manual boopsi section
-
- PowerUPKernel/PPCEnqueue PowerUPKernel/PPCEnqueue
-
- NAME
- PPCEnqueue -- insert or append node to a system queue
-
- SYNOPSIS
- PPCEnqueue(list, node)
- gpr3 gpr4
-
- void PPCEnqueue(struct List *, struct Node *);
-
- FUNCTION
- Insert or append a node into a system queue. The insert is
- performed based on the node priority -- it will keep the list
- properly sorted. New nodes will be inserted in front of the first
- node with a lower priority. Hence a FIFO queue for nodes of equal
- priority
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- list - a pointer to the system queue header
- node - the node to enqueue. This must be a full featured node
- with type, priority and name fields.
-
- SEE ALSO
- PPCAddHead(), PPCAddTail(),
- PPCInsert(), PPCRemove(),
- PPCRemHead(), PPCRemTail()
-
- PowerUPKernel/PPCEnqueueSync PowerUPKernel/PPCEnqueueSync
-
- NAME
- PPCEnqueueSync -- sync insert or append node to a system queue
-
- SYNOPSIS
- PPCEnqueueSync(list, node)
- gpr3 gpr4
-
- void PPCEnqueueSync(struct List *, struct Node *);
-
- FUNCTION
- Insert or append a node into a system queue. The insert is
- performed based on the node priority -- it will keep the list
- properly sorted. New nodes will be inserted in front of the first
- node with a lower priority. Hence a FIFO queue for nodes of equal
- priority
-
- INPUTS
- list - a pointer to the system queue header
- node - the node to enqueue. This must be a full featured node
- with type, priority and name fields.
-
- SEE ALSO
- PPCAddHeadSync(), PPCAddTailSync(),
- PPCInsertSync(), PPCRemoveSync(),
- PPCRemHeadSync(), PPCRemTailSync()
-
- PowerUPKernel/PPCFindName PowerUPKernel/PPCFindName
-
- NAME
- PPCFindName -- find a system list node with a given name
-
- SYNOPSIS
- node = PPCFindName(start, name)
- gpr3 gpr3 gpr4
-
- struct Node *PPCFindName(struct List *, STRPTR);
-
- FUNCTION
- Traverse a system list until a node with the given name is found.
- To find multiple occurrences of a string, this function may be
- called with a node starting point.
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- start - a list header or a list node to start the search
- (if node, this one is skipped)
- name - a pointer to a name string terminated with NULL
-
- RESULTS
- node - a pointer to the node with the same name else
- NULL to indicate that the string was not found.
-
- PowerUPKernel/PPCFindNameSync PowerUPKernel/PPCFindNameSync
-
- NAME
- PPCFindNameSync -- sync find a system list node with a given name
-
- SYNOPSIS
- node = PPCFindNameSync(start, name)
- gpr3 gpr3 gpr4
-
- struct Node *PPCFindNameSync(struct List *, STRPTR);
-
- FUNCTION
- Traverse a system list until a node with the given name is found.
- To find multiple occurrences of a string, this function may be
- called with a node starting point.
-
- INPUTS
- start - a list header or a list node to start the search
- (if node, this one is skipped)
- name - a pointer to a name string terminated with NULL
-
- RESULTS
- node - a pointer to the node with the same name else
- zero to indicate that the string was not found.
-
- PowerUPKernel/PPCFindTagItem PowerUPKernel/PPCFindTagItem
-
- NAME
- PPCFindTagItem -- Scans TagItem list for a Tag.
-
- SYNOPSIS
- tag = PPCFindTagItem( tagVal, tagList)
- gpr3 gpr3 gpr4
-
- struct TagItem *PPCFindTagItem(Tag tagVal,struct TagItem *tagList);
-
- FUNCTION
- Scans a TagItem "List", which is in fact a chain of arrays
- of TagItem structures as defined in utility/tagitem.h.
- Returns a pointer to the FIRST item with ti_Tag matching the
- 'TagVal' parameter.
-
- INPUTS
- tagVal - Tag value to search for.
- tagList - beginning of TagItem list to scan.
-
- RESULT
- Returns a pointer to the item with ti_Tag matching 'TagVal'.
- Returns NULL if there is no match or if TagList is NULL.
-
- SEE ALSO
- utility/tagitem.h, PPCGetTagData(), PPCNextTagItem()
-
- PowerUPKernel/PPCFindTask PowerUPKernel/PPCFindTask
-
- NAME
- PPCFindTask -- find a PPC task with the given name or find oneself
-
- SYNOPSIS
- task = PPCFindTask(name)
- gpr3 gpr4
-
- void* PPCFindTask(char*);
-
- FUNCTION
- This function will check all PPC task queues for a task with
- the given name, and return a pointer to its task control block.
- If a NULL name pointer is given a pointer to the current task
- will be returned.
-
- Finding oneself with a NULL for the name is very quick. Finding a
- task by name is very system expensive, and will disable PPCTask
- switching for a long time.
-
- INPUT
- name - pointer to a name string
-
- RESULT
- PPCtask - PPCTask Object
-
- PowerUPKernel/PPCFinishTask PowerUPKernel/PPCFinishTask
-
- NAME
- PPCFinishTask -- End your PPC Task
-
- SYNOPSIS
- PPCFindishTask(Result)
-
- void PPCFinishTask(ULONG)
-
- FUNCTION
- Ends the current task and removes it from the tasklist.
- Then it sends the M68k Msgtask the Finish Msg which may
- send back the Startup message or notify the debugger
- by the exit of the ppc task.
- This function doesn`t free the ElfObject.
-
- RESULT
- Result - Result code of the task.
-
- SEE ALSO
- ppc.library/PPCDeleteTask()
-
- PowerUPKernel/PPCfprintf PowerUPKernel/PPCfprintf
-
- NAME
- PPCfprintf -- formatted print
-
- SYNOPSIS
- Length = PPCfprintf(File, FmtString, ...)
- gpr3 gpr3 gpr4
-
- int PPCfprintf(void*, const char*, ...);
-
- FUNCTION
- does a format output to a file with stack parameters.
-
- INPUTS
- File - File returned by PPCOpen
- FmtString - FmtString described in PPCRawDoFmt()
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCvfprintf
-
- PowerUPKernel/PPCFreeMem PowerUPKernel/PPCFreeMem
-
- NAME
- PPCFreeMem -- Frees a PPC cache aligned memory block
-
- SYNOPSIS
- PPCFreeMem(Memory,size)
- gpr3 gpr4
-
- void PPCFreeMem(APTR,ULONG);
-
- FUNCTION
- Frees a memoryblock which was allocated by PPCAllocMem
-
- INPUTS
- MemoryBlock - memory block
- Size - memory block size
-
- NOTES
- The reason for this routine is that there's a serious
- cache copyback problem when ppc cache line and 68060 cache line
- cross borders. Then the contents of the memory isn't guranteed.
- The cache issue is explained in detail in Docs/PowerUP.guide
-
- SEE ALSO
- PPCAllocMem(), exec/memory.h
-
- PowerUPKernel/PPCFreePooled PowerUPKernel/PPCFreePooled
-
- NAME
- PPCFreePooled -- Free pooled memory
-
- SYNOPSIS
- PPCFreePooled(poolHeader,memory,memSize)
- gpr3 gpr4 gpr5
-
- void PPCFreePooled(void *,void *,ULONG);
-
- FUNCTION
- Deallocates memory allocated by AllocPooled(). The size of the
- allocation *MUST* match the size given to AllocPooled().
- The reason the pool functions do not track individual allocation
- sizes is because many of the uses of pools have small allocation
- sizes and the tracking of the size would be a large overhead.
-
- Only memory allocated by AllocPooled() may be freed with this
- function!
-
- Doing a DeletePool() on the pool will free all of the puddles
- and thus all of the allocations done with AllocPooled() in that
- pool. (No need to FreePooled() each allocation)
-
- INPUTS
- memory - pointer to memory allocated by AllocPooled.
- poolHeader - a specific private pool header.
-
- NOTES
- The pool function do not protect an individual pool from
- multiple accesses. The reason is that in most cases the pools
- will be used by a single task. If your pool is going to
- be used by more than one task you must Semaphore protect
- the pool from having more than one task trying to allocate
- within the same pool at the same time.
-
- SEE ALSO
- PPCAllocPooled(), PPCCreatePool(), PPCDeletePool()
-
- PowerUPKernel/PPCFreeSignal PowerUPKernel/PPCFreeSignal
-
- NAME
- PPCFreeSignal -- free a signal PPC task bit
-
- SYNOPSIS
- PPCFreeSignal(signalNum)
- gpr3
-
- void PPCFreeSignal(ULONG);
-
- FUNCTION
- This function frees a previously allocated signal bit for reuse.
- This call must be performed while running in the same PPC task
- in which the signal was allocated.
-
- INPUTS
- signalNum - the signal number to free {0..31}.
-
- SEE ALSO
- PPCAllocSignal()
-
- PowerUPKernel/PPCFreeVec PowerUPKernel/PPCFreeVec
-
- NAME
- PPCFreeVec -- return PPCAllocVec() memory to the system
-
- SYNOPSIS
- PPCFreeVec(memoryBlock)
- gpr3
-
- void PPCFreeVec(void *);
-
- FUNCTION
- Free an allocation made by the PPCAllocVec() call. The memory will
- be returned to the system pool from which it came.
-
- INPUTS
- memoryBlock - pointer to the memory block to free, or NULL.
-
- SEE ALSO
- PPCAllocVec(), exec/memory.h
-
- PowerUPKernel/PPCFreeVecPooled PowerUPKernel/PPCFreeVecPooled
-
- NAME
- PPCFreeVecPooled -- return PPCAllocVecPooled() memory to the system
-
- SYNOPSIS
- PPCFreeVecPooled(Pool,memoryBlock)
- gpr3 gpr4
-
- void PPCFreeVecPooled(void*,void *);
-
- FUNCTION
- Free an allocation made by the PPCAllocVecPooled() call. The memory will
- be returned to the system pool from which it came.
-
- INPUTS
- memoryBlock - pointer to the memory block to free, or NULL.
-
- SEE ALSO
- PPCAllocVecPooled()
-
- PowerUPKernel/PPCGetAttr PowerUPKernel/PPCGetAttr
-
- NAME
- PPCGetAttr -- Get PPC Attr (V45)
-
- SYNOPSIS
- Result = PPCGetAttr(Tag)
- gpr3 gpr3
-
- ULONG PPCGetAttr(ULONG);
-
- FUNCTION
- Gives you infos about the PPC enviroment depending on the tag.
-
- BUGS
- I can`t remember anymore what ridden me when i added this
- function to the PPC side. For some reason it`s not equal
- to the 68k side`s function.
- Anyway...it`s not that bad in the end.
- You can`t specify any CPU as on the 68k side.
- And the real annoyance..but now documented..PPCINFOTAG_PLL
- returned the PLL << 28 instead of in the lower 4 bits.
- It simply returned the hid1 registers.
- On the 68k lib side that was correct.
- Too bad nobody send a bugreport close after the damage was
- done.
-
- INPUTS
- Tags - The supported tags
-
- o PPCINFOTAG_CPU
- returns the version of the processor to detect the PPC
- type the system is running on. See your PowerPC Manuals
- "pvr" descriptions and check out the include "/ppclib/ppc.h.
- Use the ti_Data field as the processor number.
-
- o PPCINFOTAG_CPUREV
- returns the revision of the processor.
-
- o PPCINFOTAG_CPUCOUNT
- returns the numbers of processors
-
- o PPCINFOTAG_CPUCLOCK
- returns the clock of the cpu in Mhz.
-
- o PPCINFOTAG_CPUPLL (V45)
- returns the clock devider of the cpu.
- (PLL << 28) == hid1 output.
- Look at the described bugs above.
- (Please don`t use this..as it`s hw dependent anyway)
-
- RESULT
- result - depends on the requested Tags
-
- SEE ALSO
- ppclib/ppc.h
-
- PowerUPKernel/PPCGetLibSymbol PowerUPKernel/PPCGetLibSymbol
-
- NAME
- PPCGetLibSymbol -- Get a symbol of a Shared Object (V46)
-
- SYNOPSIS
- Value = PPCGetLibSymbol(LibObject,Symbol)
-
- void* PPCGetLibSymbol(void*,char*);
- gpr3 gpr4
-
- FUNCTION
- Get the value of a shared elf object symbol.
-
- INPUTS
- LibObject - shared library object
- Name - name of the symbol
-
- RESULT
- Value - depending on the symbol type it`s a ptr or a value
-
- NOTES
- Simular to the NetBSD dlopen(), dlclose(), dlsym() interface.
- If there`s a working ld a dynamic symbol link shouldn`t be
- the problem anymore but at the moment LD isn`t useful.
-
- SEE ALSO
- PPCOpenLibrary(), PPCCloseLibrary()
-
- PowerUPKernel/PPCGetMessage PowerUPKernel/PPCGetMessage
-
- NAME
- PPCGetMessage -- Gets a PPC Message from a PPC Port
-
- SYNOPSIS
- Message = PPCGetMessage(PPCPort)
- gpr3 gpr3
-
- void* PPCGetMessage(void*);
-
- FUNCTION
- Checks for a message in the PPCPort`s msglist and removes
- it from the queue.
- Until you haven`t replied the PPC Message you can read from
- the embedded Data field informations. You MUST NOT write to
- these informations.
-
- INPUTS
- PPCPort - Ptr to PPC Port
-
- RESULT
- PPCMessage - First PPC Message in the PPC Port msglist or NULL if the
- the msglist is empty.
-
- SEE ALSO
- PPCReplyMessage(), PPCCreateMessage(),
- powerup/ppclib/message.h
-
- PowerUPKernel/PPCGetMessageAttr PowerUPKernel/PPCGetMessageAttr
-
- NAME
- PPCGetMessageAttr -- Get Infos about a PPC Message
-
- SYNOPSIS
- Result = PPCGetMessageAttr(PPCMessage,Attr)
- gpr3 gpr3 gpr4
-
- ULONG PPCGetMessageAttr(void*,ULONG);
-
- FUNCTION
- Returns informations about a PPC Message. This way you
- can get a Ptr to the Data the message transports and
- the length of the message.
-
- INPUTS
- PPCMessage - Ptr to an object generated by PPCCreateMessage
- Attr - Information Attribute
- o PPCMSGTAG_DATA
- returns the Data parameter of the PPC Message.
- The Data field is most of a time a memory ptr
- but if the length of the message is 0 it can
- also be used as an additional msgid.
- o PPCMSGTAG_DATALENGTH
- returns the Length of the PPC Message. If the
- Length is NULL this Message needed no cacheflush
- and therefore is very fast. If Length is NULL the
- the Data field can be used as an additional msgid.
- o PPCMSGTAG_MSGID
- returns the MSGID of the PPC Message. This may be
- useful to mark certain msgs to be from a certain
- type which may simplify the handling of messages.
-
- RESULT
- Result - Returns the informations you requested by the
- attribute.
-
- SEE ALSO
- PPCGetMessage(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCGetObjectAttrs PowerUPKernel/PPCGetObjectAttrs
-
- NAME
- PPCGetObjectAttrs -- Get Elf Object File(s) information (V46)
-
- SYNOPSIS
- Result = PPCGetObjectAttrs(ElfObject,PPCObjectInfo,Tags )
- gpr3 gpr3 gpr4 gpr5
-
- ULONG PPCGetObjectAttrs(void*,struct PPCObjectInfo*,struct TagItem*);
-
- FUNCTION
- Gives you certain informations about an ELF PPC binary object
- or all loaded Elf objects. This way you could get certain
- symbols,types and all that.
-
- INPUTS
- ElfObject - ElfObject returned by PPCLoadObject()
- Tags - Array of Tags
-
- RESULT
-
- NOTES
- ELF will be the only format allowed the PowerUP. We don't
- want alien formats.
-
- BUGS
- Probably a lot
-
- SEE ALSO
- PPCLoadObject(), powerup/ppclib/object.h
-
- PowerUPKernel/PPCGetPortListAttr PowerUPKernel/PPCGetPortListAttr
-
- NAME
- PPCGetPortListAttr -- Get Infos about a PPC PortList
-
- SYNOPSIS
- Result = PPCGetPortListAttr(PPCPortList,Attr)
- gpr3 gpr3 gpr4
-
- ULONG PPCGetPortListAttr(void*,ULONG);
-
- FUNCTION
- Returns informations about a PPC PortList. This way you
- can get the needed received signal mask in the case you
- use the extended signalmask
-
- INPUTS
- PPCPortList - Ptr to a PPCPortList object
- Attr - Information Attribute
- o PPCPORTLISTTAG_EXTENDEDSIGNALS
- returns the extended signal mask.
- o PPCPORTLISTTAG_RECEIVEDSIGNALS
- returns the received signal mask. You need this to see
- if a msg was received AND if you also got a signal from
- the extended signalmask.
-
- SEE ALSO
- PPCCreatePortList(), PPCPortList(),
- powerup/ppclib/message.h
-
- PowerUPKernel/PPCGetTagData PowerUPKernel/PPCGetTagData
-
- NAME
- PPCGetTagData -- Obtain data corresponding to Tag.
-
- SYNOPSIS
- value = PPCGetTagData(tagVal, default, tagList)
- gpr3 gpr3 gpr4 gpr5
-
- ULONG PPCGetTagData(Tag TagVal, ULONG Default, struct TagItem *TagList)
-
- FUNCTION
- Searches a TagItem list for a matching Tag value, and returns the
- corresponding ti_Data value for the TagItem found. If none
- found, will return the value passed it as 'default'.
-
- INPUTS
- tagVal - Tag value to search for.
- default - value to be returned if tagVal is not found.
- tagList - the TagItem list to search.
-
- RESULT
- value - The ti_Data value for first matching TagItem, or
- 'default' if a ti_Tag matching 'Tag' is not found.
- SEE ALSO
- utility/tagitem.h, PPCFindTagItem(), PPCNextTagItem()
-
- PowerUPKernel/PPCGetTaskAttr PowerUPKernel/PPCGetTaskAttr
-
- NAME
- PPCGetTaskAttr -- Get PPC Task Attributes
-
- SYNOPSIS
- Result = PPCGetTaskAttr(Tag)
- gpr3 gpr3
-
- ULONG PPCGetTaskAttr(ULONG);
-
- FUNCTION
- Gives you infos about your task. This function isn`t as flexible
- the AmigaOS ppc.library function. Please check the include which
- Tag you can use.
-
- INPUTS
- Tag - the information you want.
- o PPCTASKTAG_STARTUP_MSG
- returns the PPCTask`s startup msg. This msg will be replied
- by the PowerUPKernel after the PPC Task ends so you can use
- this method to check that the PPCTask is gone so a PPCUnLoadObject()
- is save. On the PPC side you can use it as a method to pass
- data.
- o PPCTASKTAG_STARTUP_MSGDATA
- returns the startup`s MsgData. This data field can be used
- to pass startup data to the PPC. Like some M68k msgport for
- example.
- o PPCTASKTAG_STARTUP_MSGLENGTH
- returns the startup`s MsgLength.
- o PPCTASKTAG_STARTUP_MSGID
- returns the startup`s MsgID.
- o PPCTASKTAG_MSGPORT
- returns the PPCPort which belongs to the PPCTask. If you
- haven`t asked for one in PPCCreateTask() the function returns
- NULL.
- o PPCTASKTAG_STACKSIZE
- returns the size of the task`s stack.
- o PPCTASKTAG_EXTUSERDATA
- returns the extended userdata..used by ixemul
-
- RESULT
- result - depends on the requested Tag
-
- SEE ALSO
- powerup/ppclib/tasks.h
-
- PowerUPKernel/PPCGetTimerObject PowerUPKernel/PPCGetTimerObject
-
- NAME
- PPCGetTimerObject -- get informations from a TimerObject
-
- SYNOPSIS
- PPCGetTimerObject(TimerObject, Tag , ResultPtr);
- gpr3 gpr4 gpr5
-
- void PPCGetTimerObject(void*,ULONG,unsigned long long*); (GCC)
- void PPCGetTimerObject(void*,ULONG,ULONG *[2]); (SAS)
-
- FUNCTION
-
- INPUT
- TimerObject -- an object created with PPCCreateTimerObject
- Tag -- information attribute
- o PPCTIMERTAG_TICKSPERSEC
- returns the number of ticks each second
- o PPCTIMERTAG_START
- It returns the saved CPU tick counter which was saved before
- by a PPCSetTimerObject(,PPCTIMERTAG_START,);
- o PPCTIMERTAG_STOP
- It returns the saved CPU tick counter which was saved before
- by a PPCSetTimerObject(,PPCTIMERTAG_STOP,);
- o PPCTIMERTAG_CURRENTTICKS
- returns the current CPU tick count
- o PPCTIMERTAG_DIFFTICKS
- returns the difference between the START and STOP of the
- CPU timerobject in ticks.
- o PPCTIMERTAG_DIFFMICRO
- returns the difference between the START and STOP of the
- CPU timerobject in micros.
- o PPCTIMERTAG_DIFFSECS
- returns the difference between the START and STOP of the
- CPU timerobject in seconds.
- o PPCTIMERTAG_DIFFMINS
- returns the difference between the START and STOP of the
- CPU timerobject in mins.
- o PPCTIMERTAG_DIFFHOURS
- returns the difference between the START and STOP of the
- CPU timerobject in hours.
- o PPCTIMERTAG_DIFFDAYS
- returns the difference between the START and STOP of the
- CPU timerobject in days.
-
- ResultPtr -- Ptr to an unsigned long long or ULONG[2] where
- the result is stored.
-
- SEE ALSO
- PPCCreateTimerObject(), PPCDeleteTimerObject(), PPCSetTimerObject()
-
- PowerUPKernel/PPCInsert PowerUPKernel/PPCInsert
-
- NAME
- PPCInsert -- insert a node into a list
-
- SYNOPSIS
- PPCInsert(list, node, listNode)
- gpr3 gpr4 gpr5
-
- void PPCInsert(struct List*, struct Node*, struct Node*);
-
- FUNCTION
- Insert a node into a doubly linked list AFTER a given node
- position. Insertion at the head of a list is possible by
- passing a NULL listNode, though the PPCAddHead() function is
- slightly faster for that special case.
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- list - a pointer to the target list header
- node - the node to insert
- listNode - the node after which to insert
-
- SEE ALSO
- PPCAddHead(), PPCAddTail(),
- PPCEnqueue(), PPCRemHead(),
- PPCRemove(), PPCRemTail()
-
- PowerUPKernel/PPCInsertSync PowerUPKernel/PPCInsertSync
-
- NAME
- PPCInsertSync -- sync insert a node into a list
-
- SYNOPSIS
- PPCInsertSync(list, node, listNode)
- gpr3 gpr4 gpr5
-
- void PPCInsertSync(struct List *, struct Node *, struct Node *);
-
- FUNCTION
- Insert a node into a doubly linked list AFTER a given node
- position. Insertion at the head of a list is possible by
- passing a NULL listNode, though the PPCAddHead() function
- is slightly faster for that special case.
-
- INPUTS
- list - a pointer to the target list header
- node - the node to insert
- listNode - the node after which to insert
-
- SEE ALSO
- PPCAddHeadSync(), PPCAddTailSync(),
- PPCEnqueueSync(), PPCRemHeadSync(),
- PPCRemoveSync(), PPCRemTailSync()
-
- PowerUPKernel/PPCkprintf PowerUPKernel/PPCkprintf
-
- NAME
- PPCkprintf -- formatted print to the serial
-
- SYNOPSIS
- Length = PPCkprintf(FmtString, ...)
- gpr3 gpr3
-
- int PPCkprintf(const char*, ...);
-
- FUNCTION
- does a format output to the serial with stack parameters.
-
- INPUTS
- FmtString - FmtString described in PPCRawDoFmt()
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCvprintf
-
- PowerUPKernel/PPCLoadObject PowerUPKernel/PPCLoadObject
-
- NAME
- PPCLoadObject -- Load ELF PPC File (V46)
-
- SYNOPSIS
- ElfObject = PPCLoadObject(Name)
- gpr3 gpr3
-
- void *PPCLoadObject(char*);
-
- FUNCTION
- Loads an ELF PPC binary which is created by gcc for
- example. It can only handle relocatable ELF binaries
- (ld -r option)
-
- INPUTS
- name - filename
-
- RESULT
- object - ELF Program object which can be started by
- PPCCreateTask()
-
- NOTE
- ELF will be the only format allowed the PowerUP. We don't
- want alien formats.
-
- SEE ALSO
- PPCUnLoadObject(), PPCCreateTask()
-
- PowerUPKernel/PPCLoadObjectTagList PowerUPKernel/PPCLoadObjectTagList
-
- NAME
- PPCLoadObjectTagList -- Create a PPC Object from an ELF Stream (V46)
- PPCLoadObjectTags -- Varargs Stub for PPCLoadObjectTagList
-
- SYNOPSIS
- ElfObject = PPCLoadObjectTagList(Tags )
- gpr3 gpr3
-
- void *PPCLoadObjectTagList(struct TagItem*);
- void *PPCLoadObjectTags(...);
-
- FUNCTION
- Creates an PPC Object from an ELF PPC binary which is created by gcc
- for example. It can only handle relocatable ELF binaries
- (ld -r option). This call is similar to PPCLoadObject() but allows to
- create objects from ELF files that are already resident in memory.
-
- INPUTS
- tags - The Tags you want.
- o PPCELFLOADTAG_ELFNAME
- pointer to a filename of the elf file or the name of the stram.
- o PPCELFLOADTAG_ELFADDRESS
- pointer to the elf stream resident in memory.
- PPCELFLOBJTAG_ELFNAME is the object name then.
- o PPCELFLOADTAG_ELFLENGTH
- length of the elf stream. This tag is optional
- o PPCELFLOADTAG_HOOK
- Stream IO hook which can be used to replace the open,read,seek
- stream functions.
- APTR CallHookPkt(hook,StreamHandle,ElfStreamMsg);
- The result of this function must be Type depended.
- Please read powerup/ppclib/object.h for more informations.
-
- RESULT
- object - ELF Program object which can be started by
- PPCCreateTask()
-
- NOTES
- ELF will be the only format allowed the PowerUP. We don't
- want alien formats.
- PPCLOBJTAG_ELFNAME and PPCLOBJTAG_ELFADDRESS are mutually exclusive.
-
- SEE ALSO
- PPCUnLoadObject(), PPCLoadObject(), PPCCreateTask()
-
- PowerUPKernel/PPCLsl64 PowerUPKernel/PPCLsl64
-
- NAME
- PPCLsl64 -- Logical Shift left an unsigned 64 bit integer (V46)
-
- SYNOPSIS
- Value = PPCLsl64(ValueA , ShiftOffset)
- gpr3:gpr4 gpr3:gpr4 gpr5
-
- long long PPCLsl64(long long, int);
-
- FUNCTION
- Logical shift left a long long value and return a long long result.
-
- INPUTS
- ValueA - long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCLsl64p()
-
- PowerUPKernel/PPCLsl64p PowerUPKernel/PPCLsl64p
-
- NAME
- PPCLsl64p -- Logical Shift left an unsigned 64 bit integer (V46)
-
- SYNOPSIS
- PPCLsl64p(ValuePtrA, Shiftoffset)
- gpr3 gpr4
-
- void PPCLsl64p(long*,int);
-
- FUNCTION
- Logical shift left a long long value and return at return
- at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCLsl64()
-
- PowerUPKernel/PPCLsr64 PowerUPKernel/PPCLsr64
-
- NAME
- PPCLsr64 -- Logical Shift right an unsigned 64 bit integer (V46)
-
- SYNOPSIS
- Value = PPCLsr64(ValueA , ShiftOffset)
- gpr3:gpr4 gpr3:gpr4 gpr5
-
- long long PPCLsr64(long long, int);
-
- FUNCTION
- Logical shift right a long long value and return a long long result.
-
- INPUTS
- ValueA - long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCLsr64p()
-
- PowerUPKernel/PPCLsr64p PowerUPKernel/PPCLsr64p
-
- NAME
- PPCLsr64p -- Logical Shift right an unsigned 64 bit integer (V46)
-
- SYNOPSIS
- PPCLsr64p(ValuePtrA, Shiftoffset)
- gpr3 gpr4
-
- void PPCLsr64p(long*,int);
-
- FUNCTION
- Logical shift right a long long value and return at return
- at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ShiftOffset - integer value(0..63)
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCLsr64()
-
- PowerUPKernel/PPCMods64 PowerUPKernel/PPCMods64
-
- NAME
- PPCMods64 -- Modulus 2 signed 64bit integers
-
- SYNOPSIS
- Result = PPCMods64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCMods64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Multiplies 2 signed 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCMods64p()
-
- PowerUPKernel/PPCMods64p PowerUPKernel/PPCMods64p
-
- NAME
- PPCMods64p -- Modulus 2 signed 64bit integers
-
- SYNOPSIS
- PPCMods64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCMods64p(long long*,long long*);
-
- FUNCTION
- Multiplies 2 signed 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCMods64()
-
- PowerUPKernel/PPCModu64 PowerUPKernel/PPCModu64
-
- NAME
- PPCModu64 -- Modulus 2 unsigned 64bit integers
-
- SYNOPSIS
- Result = PPCModu64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCModu64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Multiplies 2 unsigned 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCModu64p()
-
- PowerUPKernel/PPCModu64p PowerUPKernel/PPCModu64p
-
- NAME
- PPCModu64p -- Modulus 2 unsigned 64bit integers
-
- SYNOPSIS
- PPCModu64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCModu64p(long long*,long long*);
-
- FUNCTION
- Multiplies 2 unsigned 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCModu64()
-
- PowerUPKernel/PPCMuls64 PowerUPKernel/PPCMuls64
-
- NAME
- PPCMuls64 -- Multiply 2 signed 64bit integers
-
- SYNOPSIS
- Result = PPCMuls64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCMuls64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Multiplies 2 signed 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCMuls64p()
-
- PowerUPKernel/PPCMuls64p PowerUPKernel/PPCMuls64p
-
- NAME
- PPCMuls64p -- Multiply 2 signed 64bit integers
-
- SYNOPSIS
- PPCMuls64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCMuls64p(long long*,long long*);
-
- FUNCTION
- Multiplies 2 signed 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCMuls64()
-
- PowerUPKernel/PPCMulu64 PowerUPKernel/PPCMulu64
-
- NAME
- PPCMulu64 -- Multiply 2 unsigned 64bit integers
-
- SYNOPSIS
- Result = PPCMulu64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCMulu64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Multiplies 2 unsigned 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCMulu64p()
-
- PowerUPKernel/PPCMulu64p PowerUPKernel/PPCMulu64p
-
- NAME
- PPCMulu64p -- Multiply 2 unsigned 64bit integers
-
- SYNOPSIS
- PPCMulu64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCMulu64p(long long*,long long*);
-
- FUNCTION
- Multiplies 2 unsigned 64bit integers and
- returns the 64bit result in A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCMulu64()
-
- PowerUPKernel/PPCNeg64 PowerUPKernel/PPCNeg64
-
- NAME
- PPCNeg64 -- Negate a 64bit integer
-
- SYNOPSIS
- Result = PPCNeg64(highA,lowA)
- gpr3:gpr4 gpr3 gpr4
-
- long PPCNeg64(ULONG,ULONG);
-
- FUNCTION
- Negates a 64bit integers and returns the 64bit result in 2
- 32bit registers.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCNeg64p()
-
- PowerUPKernel/PPCNeg64p PowerUPKernel/PPCNeg64p
-
- NAME
- PPCNeg64p -- Negate a 64bit integer
-
- SYNOPSIS
- PPCNeg64p(ValueAPtr)
- gpr3
-
- void PPCNeg64p(long long*);
-
- FUNCTION
- Negates a 64bit integer and returns the 64bit result in
- A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
-
- SEE ALSO
- PPCNeg64()
-
- PowerUPKernel/PPCNewList PowerUPKernel/PPCNewList
-
- NAME
- PPCNewList - Initialize a list (minlist) header...
-
- SYNOPSIS
- PPCNewList(list)
- gpr3
-
- VOID PPCNewList(struct List *);
- VOID PPCNewList(struct MinList *);
-
- FUNCTION
- Initializes a List so it can be used by list operations.
-
- INPUTS
- list - pointer to a List or MinList.
-
- SEE ALSO
- <exec/lists.h>
-
- PowerUPKernel/PPCNextTagItem PowerUPKernel/PPCNextTagItem
-
- NAME
- PPCNextTagItem -- Iterate TagItem lists.
-
- SYNOPSIS
- next_tag = PPCNextTagItem(tagItemPtr )
- D0 gpr3
-
- struct TagItem *PPCNextTagItem(struct TagItem **tagItemPtr);
-
- FUNCTION
- Iterates through a (chained) array of TagItem structures,
- skipping and chaining as dictated by system tags. TAG_SKIP
- will cause it to skip the entry and the next, TAG_IGNORE ignores
- that single entry, and TAG_MORE has a pointer to another array
- of tags (and terminates the current array!) TAG_DONE also
- terminates the current array. Each call returns either the next
- tagitem you should examine, or NULL at the end.
-
- INPUTS
- tagItemPtr - doubly-indirect reference to a TagItem structure.
- The pointer will be changed to keep track of the
- iteration.
-
- RESULT
- next_tag - Each TagItem in the array or chain of arrays that
- should be processed according to system Tag values
- (in utility/tagitem.h) is returned in turn with
- successive calls.
-
- EXAMPLE
- Iterate( struct TagItem *tags );
- {
- struct TagItem *tstate;
- struct TagItem *tag;
-
- tstate = tags;
- while ( tag = NextTagItem( &tstate ) )
- {
- switch ( tag->ti_Tag )
- {
- case TAG1:
- ...
- break;
- case TAG2:
- ...
- break;
- ...
- }
- }
- }
-
- NOTES
- Do NOT use the value of *tagItemPtr, but rather use the pointer
- returned by PPCNextTagItem().
-
-
- SEE ALSO
- utility/tagitem.h, PPCGetTagData(), PPCFindTagItem()
-
- PowerUPKernel/PPCObtainPort PowerUPKernel/PPCObtainPort
-
- NAME
- PPCObtainPort -- Obtain a PPC Message Port
-
- SYNOPSIS
- Port = PPCObtainPort(Tags)
- gpr3 gpr3
-
- void* PPCObtainPort(struct TagItem*);
-
- FUNCTION
- searches a public PPC MsgPort on the local processor or
- all processor. A search on the network may also be possible
- in the future.
-
- INPUTS
- Tags - Tags to specify a public port for example.
- o PPCPORTTAG_NAME,"Name"
- defines the name of the PPC port you want to obtain
-
- o PPCPORTTAG_ERROR,(ULONG*) ErrorPtr
- defines the ptr for a more precise return error result
-
- RESULT
- PPCPort - PPCPort object generated by PPCCreatePort
-
- SEE ALSO
- PPCReleasePort(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCObtainSemaphore PowerUPKernel/PPCObtainSemaphore
-
- NAME
- PPCObtainSemaphore -- gain exclusive access to a semaphore
-
- SYNOPSIS
- PPCObtainSemaphore(Semaphore)
- gpr3
-
- void ObtainSemaphore(void*);
-
- FUNCTION
- Semaphores are used to gain exclusive access to an object.
- PPCObtainSemaphore is the call used to gain this access. If another
- user currently has the semaphore locked the call will block until
- the object is available.
-
- If the current PPC task already has locked the semaphore and attempts to
- lock it again the call will still succeed. A "nesting count" is
- incremented each time the current owning task of the semaphore calls
- PPCObtainSemaphore(). This counter is decremented each time
- PPCReleaseSemaphore() is called. When the counter returns to zero the
- semaphore is actually released, and the next waiting task is called.
-
- A queue of waiting tasks is maintained on the stacks of the waiting
- tasks. Each will be called in turn as soon as the current task
- releases the semaphore.
-
- INPUT
- Semaphore -- a semaphore object returned by PPCCreateSemaphore()
-
- SEE ALSO
- PPCObtainSemaphoreShared(), PPCObtainSemaphoreByName(),
- PPCReleaseSemaphore(), PPCAttemptSemaphore(),
- PPCAttemptSemaphoreByName()
-
- PowerUPKernel/PPCObtainSemaphoreByName PowerUPKernel/PPCObtainSemaphoreByName
-
- NAME
- PPCObtainSemaphoreByName -- obtain a public Semaphore
-
- SYNOPSIS
- PPCObtainSemaphoreByName(Name)
- gpr3
-
- void* PPCObtainSemaphoreByName(char *)
-
- FUNCTION
- Tries to find a Semaphore and obtains it.
- No Arbitration needed.
-
- INPUTS
- Name - Ptr to the name cstring
-
- RESULTS
- Semaphore - If NULL no Semaphore with that name was found
-
- SEE ALSO
- PPCAttemptSemaphoreByName()
-
- PowerUPKernel/PPCObtainSemaphoreShared PowerUPKernel/PPCObtainSemaphoreShared
-
- NAME
- PPCObtainSemaphoreShared -- gain shared access to a semaphore
-
- SYNOPSIS
- PPCObtainSemaphoreShared(Semaphore)
- gpr3
-
- void PPCObtainSemaphoreShared(void*);
-
- FUNCTION
- A lock on a semaphore may either be exclusive, or shared.
- Exclusive locks are granted by the ObtainSemaphore() and
- PPCAttemptSemaphore() functions. Shared locks are granted by
- PPCObtainSemaphoreShared(). Calls may be nested.
-
- Any number of tasks may simultaneously hold a shared lock on a
- semaphore. Only one task may hold an exclusive lock. A typical
- application is a list that is often read, but only occasionally
- written to.
-
- Any exlusive locker will be held off until all shared lockers
- release the semaphore. Likewise, if an exlusive lock is held,
- all potential shared lockers will block until the exclusive lock
- is released. All shared lockers are restarted at the same time.
-
- EXAMPLE
- ObtainSemaphoreShared(ss);
- // read data
- ReleaseSemaohore(ss);
-
- ObtainSemaphore(ss);
- // modify data
- ReleaseSemaohore(ss);
-
- INPUT
- Semaphore -- a semaphore object returned by PPCCreateSemaphore()
-
- SEE ALSO
- PPCObtainSemaphore(), PPCObtainSemaphoreByName(),
- PPCReleaseSemaphore(), PPCAttemptSemaphore(),
- PPCAttemptSemaphoreByName()
-
- PowerUPKernel/PPCOpen PowerUPKernel/PPCOpen
-
- NAME
- PPCOpen -- Open a file for input or output
-
- SYNOPSIS
- file = PPCOpen( name, accessMode )
- gpr3 gpr3 gpr4
-
- BPTR PPCOpen(STRPTR, LONG)
-
- FUNCTION
- This function is equal to the dos.library/Open function.
- It works in the context of the Msg Task each PPC Task has
- on the AmigaOS side.
-
- INPUTS
- name - pointer to a null-terminated string
- accessMode - integer
-
- RESULTS
- file - BCPL pointer to a file handle
-
- SEE ALSO
- PPCClose(), PPCRead(), PPCWrite(), PPCSeek()
-
- PowerUPKernel/PPCOpenLibrary PowerUPKernel/PPCOpenLibrary
-
- NAME
- PPCOpenLibrary -- Opens a shared object module (V46)
-
- SYNOPSIS
- LibObject = PPCOpenLibrary( Name, Tags)
-
- void* PPCOpenLibrary( char*, struct TagItem*);
- gpr3 gpr3 gpr4
-
- FUNCTION
- Loads a shared elf object. If the function
- __LIB_Init(LibObject) exists, it is executed and
- must return the LibObject if the init shouldn`t fail.
-
- INPUTS
- name - pointer to the name of the library
- tags - pointer to a tag array
- o PPCELFLOADTAG_LIBVERSION, ULONG
- ask for at least this version of the library
- o PPCELFLOADTAG_LIBREVISION, ULONG
- ask for at least this revision of the library, if
- the found library`s version is equal to the requested
- version.
- o PPCELFLOADTAG_LIBEXACTVERSION
- ask for a specific version of the library
- o PPCELFLOADTAG_LIBEXACTVERSION
- ask for a specific revision of the library
-
- RESULT
- LibObject - library object or NULL for fail
-
- NOTES
- Simular to the NetBSD dlopen(), dlclose(), dlsym() interface.
- If there`s a working ld a dynamic symbol link shouldn`t be
- the problem anymore but at the moment LD isn`t useful.
-
- SEE ALSO
- PPCCloseLibrary(), PPCGetLibSymbol(),
- powerup/ppclib/object.h
-
- PowerUPKernel/PPCOr64 PowerUPKernel/PPCOr64
-
- NAME
- PPCOr64 -- Or 2 64 bit integer values (V46)
-
- SYNOPSIS
- Value = PPCOr64(ValueA , ValueB)
- gpr3:gpr4 gpr3:gpr4 gpr5:gpr6
-
- long long PPCOr64(long long, long long);
-
- FUNCTION
- Ors 2 long long values and returns a long long result.
-
- INPUTS
- ValueA - long long value A
- ValueB - long long value B
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCOr64p()
-
- PowerUPKernel/PPCOr64p PowerUPKernel/PPCOr64p
-
- NAME
- PPCOr64p -- Or 2 64 bit integer values (V46)
-
- SYNOPSIS
- PPCOr64p(ValuePtrA, ValuePtrB)
- gpr3 gpr4
-
- void PPCOr64p(long*,long*);
-
- FUNCTION
- Ors 2 long long values and returns the result at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ValuePtrB - ptr to a long long value B
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCOr64()
-
- PowerUPKernel/PPCprintf PowerUPKernel/PPCprintf
-
- NAME
- PPCprintf -- formatted print to stdout
-
- SYNOPSIS
- Length = PPCprintf(FmtString, ...)
- gpr3 gpr3
-
- int PPCprintf(const char*, ...);
-
- FUNCTION
- does a format output to the stdout file with stack parameters.
-
- INPUTS
- FmtString - FmtString described in PPCRawDoFmt()
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCvprintf
-
- PowerUPKernel/PPCRawDoFmt PowerUPKernel/PPCRawDoFmt
-
- NAME
- RawDoFmt -- format data into a character stream.
-
- SYNOPSIS
- NextData = PPCRawDoFmt(FormatString, DataStream, PutChProc, PutChData);
- gpr3 gpr3 gpr4 gpr4 gpr5
-
- APTR PPCRawDoFmt(STRPTR,APTR,void (*)(),APTR);
-
- FUNCTION
- perform "C"-language-like formatting of a data stream, outputting
- the result a character at a time. Where % formatting commands are
- found in the FormatString, they will be replaced with the
- corresponding element in the DataStream. %% must be used in the
- string if a % is desired in the output.
-
- Under V36, RawDoFmt() returns a pointer to the end of the DataStream
- (The next argument that would have been processed). This allows
- multiple formatting passes to be made using the same data.
-
- INPUTS
- FormatString - a "C"-language-like NULL terminated format string,
- with the following supported % options:
-
- %[flags][width.Precision][length]type
-
- flags - supported flags are
- '-' - specifies left justification within the specified
- or default field width.
- '+' - causes a plus or minus sign to be placed before the
- result. If it`s not specified only the sign is
- only generated for a negative value.
- ' ' - causes a leading blank for a positive number and
- a minus for a negative number. the (plus) sign
- overrides this flag.
- '#' - causes a type depending format. With x and X types
- it generates a 0x or 0X prefix.
- With the f, e, and E type conversion it forces a
- '.' in the output.
- With the g and G types it forces a '.' and trailing
- zeroes.
- '0' - pads the field width with leading zeroes instead of
- spaces.
-
- width - field width. If the first character is a '0', the
- field will be padded with leading 0's.
- . - must follow the field width, if specified
- limit - maximum number of characters to output from a string.
- (only valid for %s).
- length - size of input data defaults to WORD for types d, x,
- and c, 'l' changes this to long (32-bit) and
- 'L' for long long (64-bit)
- type - supported types are:
- b - BSTR, data is 32-bit BPTR to byte count followed
- by a byte string, or NULL terminated byte string.
- A NULL BPTR is treated as an empty string.
- d - decimal
- u - unsigned decimal (Added in V37 exec)
- x - hexadecimal
- s - string, a 32-bit pointer to a NULL terminated
- byte string. In V36, a NULL pointer is treated
- as an empty string
- c - character
- e,E,f - the precision is the number of digits to appear
- after the decimal generated, trailing zeroes are
- supplied
- g,G - the precision is the maxium number of significant
- digits
-
- DataStream - a stream of data that is interpreted according to
- the format string. Often this is a pointer into
- the task's stack.
- PutChProc - the procedure to call with each character to be
- output, called as:
-
- PutChData = PutChProc(Char, PutChData);
- gpr3 gpr3 gpr4
-
- the procedure is called with a NULL Char at the end of
- the format string.
-
- IMPORTANT! IMPORTANT! IMPORTANT! IMPORTANT! IMPORTANT!
-
- If PutChProc is == 0 it writes the character into the Buffer.
- The buffer is the address PutChData points too.
- If PutChProc is == 1 it writes the character to the serial line.
-
-
- PutChData - a value that is passed through to the PutChProc
- procedure. This is untouched by RawDoFmt, and may be
- modified by the PutChProc.
-
- WARNING
- This Amiga ROM function formats word values in the data stream. If
- your compiler defaults to longs, you must add an "l" to your
- % specifications. This can get strange for characters, which might
- look like "%lc".
-
- SEE ALSO
- Documentation on the C language "printf" call in any C language
- reference book.
-
- PowerUPKernel/PPCRead PowerUPKernel/PPCRead
-
- NAME
- PPCRead -- Read bytes of data from a file
-
- SYNOPSIS
- actualLength = PPCRead( file, buffer, length )
- gpr3 gpr3 gpr4 gpr5
-
- LONG PPCRead(BPTR, void *, LONG)
-
- FUNCTION
- This function is equal to the dos.library/Read function.
- It works in the context of the Msg Task each PPC Task has
- on the AmigaOS side.
-
- ATTENTION
- You must use PPCAllocMem() for the buffer, so it`s aligned
- to the PPC cache lines.
-
- INPUTS
- file - BCPL pointer to a file handle
- buffer - pointer to buffer
- length - integer
-
- RESULTS
- actualLength - integer
-
- SEE ALSO
- PPCOpen(), PPCClose(), PPCWrite(), PPCSeek()
-
- PowerUPKernel/PPCReadByte PowerUPKernel/PPCReadByte
-
- NAME
- PPCReadByte -- Read a Long from the 68k side
-
- SYNOPSIS
- Result=PPCReadByte(Address)
- d0 a0
-
- ULONG PPCReadByte(UBYTE*);
-
- FUNCTION
- This function reads a long by the 68k processor.
- Quick way to read small amounts of data without cache effects
-
- RESULT
- Result - UBYTE read from the address
-
- SEE ALSO
- PPCWriteByte()
-
- PowerUPKernel/PPCReadLong PowerUPKernel/PPCReadLong
-
- NAME
- PPCReadLong -- Read a Long from the 68k side
-
- SYNOPSIS
- Result=PPCReadLong(Address)
- d0 a0
-
- ULONG PPCReadLong(ULONG*);
-
- FUNCTION
- This function reads a long by the 68k processor.
- Quick way to read small amounts of data without cache effects
-
- RESULT
- Result - ULONG read from the address
-
- SEE ALSO
- PPCWriteLong()
-
- PowerUPKernel/PPCReadWord PowerUPKernel/PPCReadWord
-
- NAME
- PPCReadWord -- Read a Long from the 68k side
-
- SYNOPSIS
- Result=PPCReadWord(Address)
- d0 a0
-
- ULONG PPCReadWord(ULONG*);
-
- FUNCTION
- This function reads a long by the 68k processor.
- Quick way to read small amounts of data without cache effects
-
- RESULT
- Result - UWORD read from the address
-
- SEE ALSO
- PPCWriteWord()
-
- PowerUPKernel/PPCReleasePort PowerUPKernel/PPCReleasePort
-
- NAME
- PPCReleasePort -- Releases an obtained PPC Message Port
-
- SYNOPSIS
- Success = PPCReleasePort(PPCPort)
- gpr3 gpr3
-
- void PPCReleasePort(void*);
-
- FUNCTION
- Releases a PPC MsgPort, so it may be removed after nobody
- needs it anymore.
-
- INPUTS
- PPCPort - Ptr to an object generated by PPCCreatePort
-
- RESULT
- Success - Boolean which says if the PPCPort could be released
- successfully. If this fails the PPCPort is still obtained
- by somebody else.
- SEE ALSO
- PPCObtainPort(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCReleaseSemaphore PowerUPKernel/PPCReleaseSemaphore
-
- NAME
- PPCReleaseSemaphore -- make semaphore available to others
-
- SYNOPSIS
- PPCReleaseSemaphore(Semaphore)
- gpr3
-
- void PPCReleaseSemaphore(void*);
-
- FUNCTION
- PPCReleaseSemaphore() is the inverse of PPCObtainSemaphore(). It makes
- the semaphore lockable to other users. If tasks are waiting for
- the semaphore and this this task is done with the semaphore then
- the next waiting task is signalled.
-
- Each PPCObtainSemaphore() call must be balanced by exactly one
- PPCReleaseSemaphore() call. This is because there is a nesting count
- maintained in the semaphore of the number of times that the current
- task has locked the semaphore. The semaphore is not released to
- other PPC tasks until the number of releases matches the number of
- obtains.
-
- Needless to say, havoc breaks out if the task releases more times
- than it has obtained.
-
- INPUT
- Semaphore -- a semaphore object returned by PPCCreateSemaphore()
-
- SEE ALSO
- PPCObtainSemaphore(), PPCObtainSemaphoreShared()
-
- PowerUPKernel/PPCRemHead PowerUPKernel/PPCRemHead
-
- NAME
- PPCRemHead -- remove the head node from a list
-
- SYNOPSIS
- node = PPCRemHead(list)
- gpr3 gpr3
-
- struct Node *PPCRemHead(struct List *);
-
- FUNCTION
- Get a pointer to the head node and remove it from the list.
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- list - a pointer to the target list header
-
- RESULT
- node - the node removed or NULL when empty list
-
- SEE ALSO
- PPCAddHead(), PPCAddTail(),
- PPCEnqueue(), PPCInsert(),
- PPCRemove(), PPCRemTail()
-
- PowerUPKernel/PPCRemHeadSync PowerUPKernel/PPCRemHeadSync
-
- NAME
- PPCRemHeadSync -- sync remove the head node from a list
-
- SYNOPSIS
- node = PPCRemHeadSync(list)
- gpr3 gpr3
-
- struct Node *PPCRemHead(struct List *);
-
- FUNCTION
- Get a pointer to the head node and remove it from the list.
-
- INPUTS
- list - a pointer to the target list header
-
- RESULT
- node - the node removed or zero when empty list
-
- SEE ALSO
- PPCAddHeadSync(), PPCAddTailSync(),
- PPCEnqueueSync(), PPCInsertSync(),
- PPCRemoveSync(), PPCRemTailSync()
-
- PowerUPKernel/PPCRemove PowerUPKernel/PPCRemove
-
- NAME
- PPCRemove -- remove a node from a list
-
- SYNOPSIS
- PPCRemove(node)
- gpr3
-
- void PPCRemove(struct Node *);
-
- FUNCTION
- Unlink a node from whatever list it is in.
- Nodes that are not part of a list must not
- be passed to this function!
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- node - the node to remove
-
- SEE ALSO
- PPCAddHead(), PPCAddTail(),
- PPCEnqueue(), PPCInsert(),
- PPCRemHead(), PPCRemTail()
-
- PowerUPKernel/PPCRemoveSync PowerUPKernel/PPCRemoveSync
-
- NAME
- PPCRemoveSync -- sync remove a node from a list
-
- SYNOPSIS
- PPCRemoveSync(node)
- gpr3
-
- void PPCRemoveSync(struct Node *);
-
- FUNCTION
- Unlink a node from whatever list it is in. Nodes
- that are not part of a list must not be passed to
- this function!
-
- INPUTS
- node - the node to remove
-
- SEE ALSO
- PPCAddHeadSync(), PPCAddTailSync(),
- PPCEnqueueSync(), PPCInsertSync(),
- PPCRemHeadSync(), PPCRemTailSync()
-
- PowerUPKernel/PPCRemPortList PowerUPKernel/PPCRemPortList
-
- NAME
- PPCRemPortList -- Remove a port from the PPCPortList object
-
- SYNOPSIS
- PPCRemPortList(PPCPortList,PPCPort)
- gpr3 gpr4
-
- void PPCRemPortList(void*,void*);
-
- FUNCTION
- This function removes a PPCPort from your PPCPortList object.
-
- INPUT
- PPCPortList - a pointer to the PPCPortList object
- PPCPort - a pointer to the PPC Message port
-
- SEE ALSO
- PPCCreatePortList(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCRemTail PowerUPKernel/PPCRemTail
-
- NAME
- PPCRemTail -- remove the tail node from a list
-
- SYNOPSIS
- node = PPCRemTail(list)
- gpr3 gpr3
-
- struct Node *PPCRemTail(struct List *);
-
- FUNCTION
- Remove the last node from a list, and return a pointer to it.
- If the list is empty, return NULL.
-
- WARNING
- This function does not arbitrate for access to the list. The
- calling task must be the owner of the involved list.
-
- INPUTS
- list - a pointer to the target list header
-
- RESULT
- node - the node removed or NULL when empty list
-
- SEE ALSO
- PPCAddHead(), PPCAddTail(),
- PPCEnqueue(), PPCInsert(),
- PPCRemove(), PPCRemHead(),
-
- PowerUPKernel/PPCRemTailSync PowerUPKernel/PPCRemTailSync
-
- NAME
- PPCRemTailSync -- sync remove the tail node from a list
-
- SYNOPSIS
- node = PPCRemTailSync(list)
- gpr3 gpr3
-
- struct Node *PPCRemTailSync(struct List *);
-
- FUNCTION
- Remove the last node from a list, and return a pointer to it.
- If the list is empty, return NULL.
-
- INPUTS
- list - a pointer to the target list header
-
- RESULT
- node - the node removed or zero when empty list
-
- SEE ALSO
- PPCAddHeadSync(), PPCAddTailSync(),
- PPCEnqueueSync(), PPCInsertSync(),
- PPCRemoveSync(), PPCRemHeadSync(),
-
- PowerUPKernel/PPCReplyMessage PowerUPKernel/PPCReplyMessage
-
- NAME
- PPCReplyMessage -- Reply a PPC Message
-
- SYNOPSIS
- Success = PPCReplyMessage(PPCMessage)
- gpr3
-
- BOOL PPCReplyMessage(void*);
-
- FUNCTION
- Reply a PPC Message. After this operation the embedded Data
- informations in the PPC Message isn`t valid anymore. The Message
- itself is also not valid anymore so any access to the object is
- not allowed.
-
- INPUTS
- PPCMessage - Ptr to an object generated by PPCCreateMessage
-
- RESULT
- Success - A Boolean tells you if the operation was successful.
-
- SEE ALSO
- PPCGetMessage(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCRevision PowerUPKernel/PPCRevision
-
- NAME
- PPCRevision -- Get Revision of the PowerUPKernel
-
- SYNOPSIS
- Revision = PPCRevision()
- gpr3
-
- ULONG PPCVersion()
-
- FUNCTION
- Returns the Revision of the PowerUPKernel, so software
- is able to adapt to future changes.
-
- RESULT
- value - The Revision number of the PowerUPKernel
-
- PowerUPKernel/PPCSeek PowerUPKernel/PPCSeek
-
- NAME
- PPCSeek -- Set the current position for reading and writing
-
- SYNOPSIS
- oldPosition = PPCSeek( file, position, mode )
- gpr3 gpr3 gpr4 gpr5
-
- LONG PPCSeek(BPTR, LONG, LONG)
-
- FUNCTION
- This function is equal to the dos.library/Seek function.
- It works in the context of the Msg Task each PPC Task has
- on the AmigaOS side.
-
- INPUTS
- file - BCPL pointer to a file handle
- position - integer
- mode - integer
-
- RESULTS
- oldPosition - integer
-
- SEE ALSO
- PPCOpen(), PPCClose(), PPCWrite(), PPCRead()
-
- PowerUPKernel/PPCSendMessage PowerUPKernel/PPCSendMessage
-
- NAME
- PPCSendMessage -- Sends a PPC Message to a PPC Port
-
- SYNOPSIS
- Success = PPCSendMessage(PPCPort,PPCMessage,Data,Length,MsgID)
- gpr3 gpr3 gpr4 gpr5 gpr6 gpr7
-
- BOOL PPCSendMessage(void*,void*,void*,ULONG,ULONG);
-
- FUNCTION
- Sends a PPC Message to a PPC Port which may be controlled
- by the M68k oder PPC. This way you can pass data between
- the PPC and the M68k in an abstract way which will be source
- compatible on the A\BOX OS. After you`ve sent a message
- you MUST NOT change the Data until your task received a reply.
- If you only want to send a quick 32Bit Msg to the target task
- use Data as a 32bit Msg value and Length=0.
- This way no Cache is flushed.
-
- INPUTS
- PPCPort - Ptr to an object generated by PPCCreatePort
- PPCMessage - Ptr to an object generated by PPCCreateMessage
- Data - Ptr to the Data you wanna send or additional MsgID
- if the Length field is 0.
- Length - Length of the Data you wanna send.
- MsgID - MsgID code you may use for your msg type detection
-
- RESULT
- Success - A Boolean tells you if the operation was successful.
-
- SEE ALSO
- PPCReplyMessage(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCSetPortListAttr PowerUPKernel/PPCSetPortListAttr
-
- NAME
- PPCSetPortListAttr -- Set Infos about a PPC PortList
-
- SYNOPSIS
- PPCSetPortListAttr(PPCPortList,Attr)
- gpr3 gpr4
-
- void PPCSetPortListAttr(void*,ULONG);
-
- FUNCTION
- changes certain PPC PortList attributes. This way you
- can change the Extended SignalMask for example.
-
- INPUTS
- PPCPortList - Ptr to a PPCPortList object
- Attr - Information Attribute
- o PPCPORTLISTTAG_EXTENDEDSIGNALS,ExtSignalMask
- changes the PPCPortList extended signalmask to the value you specify
-
- SEE ALSO
- PPCCreatePortList(), PPCPortList(), PPCGetSetPortListAttr(),
- powerup/ppclib/message.h
-
- PowerUPKernel/PPCSetSignal PowerUPKernel/PPCSetSignal
-
- NAME
- PPCSetSignal -- define the state of this ppctask's signals
-
- SYNOPSIS
- oldSignals = PPCSetSignal(newSignals, signalMask)
- gpr3 gpr3 gpr4
-
- ULONG PPCSetSignal(ULONG, ULONG)
-
- FUNCTION
- This function defines the states of the ppctask's signalmask.
- This way you can check for break signals easily.
-
- INPUTS
- newSignals - the new values for the signals specified in
- signalSet.
- signalMask - the set of signals to be effected
-
- RESULTS
- oldSignals - the prior values for all signals
-
- EXAMPLE
- Get the current state of all signals:
- PPCSetSignal(0,0)
- Clear all signals:
- PPCSetSignal(0,FFFFFFFFH)
-
- SEE ALSO
- PPCSignal(), PPCWait()
-
- PowerUPKernel/PPCSetTaskAttr PowerUPKernel/PPCSetTaskAttr
-
- NAME
- PPCSetTaskAttr -- Get PPC Task Attributes (V46)
-
- SYNOPSIS
- PPCSetTaskAttr(Tag, Data)
- gpr3 gpr4
-
- void PPCSetTaskAttr(ULONG,ULONG);
-
- FUNCTION
- Sets a task attribute. This function isn`t as flexible
- the AmigaOS ppc.library function. Please check the include which
- Tag you can use.
-
- INPUTS
- Tag - the information you want.
- o PPCTASKTAG_EXTUSERDATA, ULONG
- sets the extended userdata..used by ixemul
- Data - the attribute datafield
-
- RESULT
-
- SEE ALSO
- powerup/ppclib/tasks.h
-
- PowerUPKernel/PPCSetTimerObject PowerUPKernel/PPCSetTimerObject
-
- NAME
- PPCSetTimerObject -- set TimerObject attributes
-
- SYNOPSIS
- PPCSetTimerObject(TimerObject, Tag , ValuePtr);
- gpr3 gpr4 gpr5
-
- void PPCSetTimerObject(void*,ULONG,unsigned long long*); (GCC)
- void PPCSetTimerObject(void*,ULONG,ULONG *[2]); (SAS)
-
- FUNCTION
-
- INPUT
- TimerObject -- an object created with PPCCreateTimerObject
- Tag -- attribute
- o PPCTIMERTAG_START
- 1) TimerObject is a CPU tick counter then it sets the
- the current timer value as the start position in the
- timerobject.
- 2) TimerObject is a 50Hz timer you can reactivate stopped
- timerjobs
- o PPCTIMERTAG_STOP
- 1) TimerObject is a CPU tick counter then it sets the
- the current timer value as the stop position in the
- timerobject.
- 2) TimerObject is a 50Hz timer you can reactivate stopped
- timerjobs
-
- ValuePtr -- Ptr to an unsigned long long or ULONG[2] where
- some optional value result. Not yet used.
-
- SEE ALSO
- PPCCreateTimerObject(), PPCDeleteTimerObject(), PPCGetTimerObject()
-
- PowerUPKernel/PPCSignal PowerUPKernel/PPCSignal
-
- NAME
- PPCSignal -- signal a PPC task
-
- SYNOPSIS
- PPCSignal(PPCTask, signals)
- gpr3 gpr4
-
- void PPCSignal(void*,ULONG);
-
- FUNCTION
- This function signals a PPC task with the given signals.
- If the task is currently waiting for one or more of these
- signals, it will be made ready and a reschedule will occur.
- If the task is not waiting for any of these signals, the
- signals will be posted to the task for possible later use.
- A signal may be sent to a task regardless of whether it is
- running, ready, or waiting.
-
- This function is considered "low level". Its main purpose
- is to support multiple higher level functions like PPCSendMessage.
-
- INPUT
- task - the task to be signalled
- signals - the signals to be sent
-
- SEE ALSO
- PPCWait(), PPCSetSignal(), PPCSendMessage()
-
- PowerUPKernel/PPCsprintf PowerUPKernel/PPCsprintf
-
- NAME
- PPCsprintf -- formatted print to a string
-
- SYNOPSIS
- Length = PPCsprintf(Buffer, FmtString, ...)
- gpr3 gpr3 gpr4
-
- int PPCsprintf(char*, const char*, ...);
-
- FUNCTION
- does a format output to a string with stack parameters.
-
- INPUTS
- Buffer - Ptr to the result string.
- FmtString - FmtString described in PPCRawDoFmt()
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCvprintf
-
- PowerUPKernel/PPCSub64 PowerUPKernel/PPCSub64
-
- NAME
- PPCSub64 -- Sub 2 64bit integers
-
- SYNOPSIS
- Result = PPCSub64(highA,lowA,highB,lowB )
- gpr3:gpr4 gpr3 gpr4 gpr5 gpr6
-
- long PPCSub64(ULONG,ULONG,ULONG,ULONG);
-
- FUNCTION
- Subtracts 2 64bit integers and returns the 64bit result in 2
- 32bit registers.
-
- INPUTS
- highA - upper 32bit of value A
- lowA - lower 32bit of value A
- highB - upper 32bit of value B
- lowB - lower 32bit of value B
-
- RESULT
- Result - 64Bit result devided into 2 registers
-
- SEE ALSO
- PPCSub64p()
-
- PowerUPKernel/PPCSub64p PowerUPKernel/PPCSub64p
-
- NAME
- PPCSub64p -- Sub 2 64bit integers
-
- SYNOPSIS
- PPCSub64p(ValueAPtr,ValueBPtr)
- gpr3 gpr4
-
- void PPCSub64p(long long*,long long*);
-
- FUNCTION
- Subtracts 2 64bit integers and returns the 64bit result in
- A.
-
- INPUTS
- ValueAPtr - Ptr to 64Bit value A
- ValueBPtr - Ptr to 64Bit value B
-
- SEE ALSO
- PPCSub64()
-
- PowerUPKernel/PPCUnLoadObject PowerUPKernel/PPCUnLoadObject
-
- NAME
- PPCUnLoadObject -- UnLoad ELF PPC Object (V46)
-
- SYNOPSIS
- PPCUnLoadObject( Object )
- gpr3
-
- void PPCUnLoadObject(void*);
-
- FUNCTION
- Unloads an Object created with PPCLoadObject().
-
- INPUTS
- object - ptr to the object given by PPCLoadObject()
-
- SEE ALSO
- PPCUnLoadObject(), PPCCreateTask()
-
- PowerUPKernel/PPCVersion PowerUPKernel/PPCVersion
-
- NAME
- PPCVersion -- Get Version of the PowerUPKernel
-
- SYNOPSIS
- Version = PPCVersion()
- gpr3
-
- ULONG PPCVersion()
-
- FUNCTION
- Returns the Version of the PowerUPKernel, so software
- is able to adapt to future changes.
-
- RESULT
- value - The version number of the PowerUPKernel
-
-
- PowerUPKernel/PPCvfprintf PowerUPKernel/PPCvfprintf
-
- NAME
- PPCvfprintf -- formatted write of a varying-length
- argument list
-
- SYNOPSIS
- Length = PPCvfprintf(File, FmtString, Args)
- gpr3 gpr3 gpr4 gpr5
-
- int PPCvfprintf(void*, const char*, va_list);
-
- FUNCTION
- does a format output to the stdout file with a ptr
- to a va_list array.
-
- INPUTS
- File - File returned by PPCOpen
- FmtString - FmtString described in PPCRawDoFmt()
- Args - va_list ptr.
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCfprintf
-
- PowerUPKernel/PPCvkprintf PowerUPKernel/PPCvkprintf
-
- NAME
- PPCvkprintf -- formatted write of a varying-length
- argument list to the serial
-
- SYNOPSIS
- Length = PPCvkprintf(FmtString, Args)
- gpr3 gpr3 gpr4
-
- int PPCvkprintf(const char*, va_list);
-
- FUNCTION
- does a format output to the serial with a ptr
- to a va_list array.
-
- INPUTS
- FmtString - FmtString described in PPCRawDoFmt()
- Args - va_list ptr.
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCprintf
-
- PowerUPKernel/PPCvprintf PowerUPKernel/PPCvprintf
-
- NAME
- PPCvprintf -- formatted write of a varying-length
- argument list to stdout
-
- SYNOPSIS
- Length = PPCvprintf(FmtString, Args)
- gpr3 gpr3 gpr4
-
- int PPCvprintf(const char*, va_list);
-
- FUNCTION
- does a format output to the stdout file with a ptr
- to a va_list array.
-
- INPUTS
- FmtString - FmtString described in PPCRawDoFmt()
- Args - va_list ptr.
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCprintf
-
- PowerUPKernel/PPCvsprintf PowerUPKernel/PPCvsprintf
-
- NAME
- PPCvsprintf -- formatted write of a varying-length
- argument list to a string
-
- SYNOPSIS
- Length = PPCvsprintf(Buffer, FmtString, Args)
- gpr3 gpr3 gpr4 gpr5
-
- int PPCvsprintf(char*, const char*, va_list);
-
- FUNCTION
- does a format output to the buffer with a ptr
- to a va_list array.
-
- INPUTS
- Buffer - Ptr to the result string.
- FmtString - FmtString described in PPCRawDoFmt()
- Args - va_list ptr.
-
- RESULT
- Length - count of char output
-
- SEE ALSO
- PPCprintf
-
- PowerUPKernel/PPCWait PowerUPKernel/PPCWait
-
- NAME
- PPCWait -- wait for one or more signals
-
- SYNOPSIS
- signals = PPCWait(signalSet)
- gpr3 gpr3
-
- ULONG PPCWait(ULONG);
-
- FUNCTION
- This function will cause the current PPC task to suspend
- waiting for one or more signals.
- When one or more of the specified signals are received,
- the task will return to the ready state, and those signals
- will be cleared.
-
- If a signal occurred prior to calling PPCWait(), the wait
- condition will be immediately satisfied, and the task will
- continue to run without any delay.
-
-
- INPUT
- signalSet - The set of signals for which to wait.
- Each bit represents a particular signal.
-
- RESULTS
- signals - the set of signals that were active
-
- SEE ALSO
- PPCSignal(), PPCSetSignal()
-
- PowerUPKernel/PPCWaitPort PowerUPKernel/PPCWaitPort
-
- NAME
- PPCWaitPort -- wait for a given PPC Msgport to be non-empty
-
- SYNOPSIS
- PPCMessage = PPCWaitPort(PPCPort)
- gpr3 gpr3
-
- void* PPCWaitPort(void*);
-
- FUNCTION
- This function waits for the given PPC Msgport to become non-empty.
- If necessary, the Wait function will be called to wait for
- the port signal. If a message is already present at the
- port, this function will return immediately. The return
- value is always a pointer to the first PPC Message queued (but
- it is not removed from the queue.
-
- INPUT
- PPCPort - a pointer to the PPC Message port
-
- RESULT
- PPCMessage - a pointer to the first PPC Message in the PPCPort msglist.
-
- SEE ALSO
- PPCGetMessage(), powerup/ppclib/message.h
-
- PowerUPKernel/PPCWaitPortList PowerUPKernel/PPCWaitPortList
-
- NAME
- PPCWaitPortList -- wait for a given PPC Msgport List to get a msg
-
- SYNOPSIS
- PPCPort = PPCWaitPortList(PPCPortList)
- gpr3 gpr3
-
- void* PPCWaitPortList(void*)
-
- FUNCTION
- This function waits for a list of PPCPorts. If a message
- is received by one of the ports the port with the msg is
- returned so you can use PPCGetMessage on that port.
- NULL is returned if no signals were received or if an extended
- signal was received. You should always check the Received
- Signals in PPCWaitPort when you use an extended Signalmask, so
- you don`t miss signals.
- It could happen that you get a message and some private signal
- and the function returns the PPCPort where the message is.
- In this case you should check the received signalmask to not
- miss your private signals.
-
- INPUT
- PPCPortList - a pointer to a PPCPortList object created by
- PPCCreatePortList()
-
- RESULT
- PPCPort - a pointer to a port which received a msg or NULL.
-
- SEE ALSO
- PPCGetMessage(), PPCWaitPort(),
- powerup/ppclib/message.h
-
- PowerUPKernel/PPCWrite PowerUPKernel/PPCWrite
-
- NAME
- PPCWrite -- Write bytes of data to a file
-
- SYNOPSIS
- returnedLength = PPCWrite( file, buffer, length )
- gpr3 gpr3 gpr4 gpr5
-
- LONG PPCWrite(BPTR, void *, LONG)
-
- FUNCTION
- This function is equal to the dos.library/Write function.
- It works in the context of the Msg Task each PPC Task has
- on the AmigaOS side.
-
- ATTENTION
- You must use PPCAllocMem() for the buffer, so it`s aligned
- to the PPC cache lines.
-
- INPUTS
- file - BCPL pointer to a file handle
- buffer - pointer to the buffer
- length - integer
-
- RESULTS
- returnedLength - integer
-
- SEE ALSO
- PPCOpen(), PPCClose(), PPCSeek(), PPCRead()
-
- PowerUPKernel/PPCWriteByte PowerUPKernel/PPCWriteByte
-
- NAME
- PPCWriteByte -- Write a Long by the 68k side
-
- SYNOPSIS
- PPCWriteByte(Address,Value)
- a0 d0
-
- void PPCWriteByte(UBYTE*,ULONG);
-
- FUNCTION
- This function writes a long by the 68k processor.
- Quick way to write small amounts of data without cache effects
-
- SEE ALSO
- PPCReadByte()
-
- PowerUPKernel/PPCWriteLong PowerUPKernel/PPCWriteLong
-
- NAME
- PPCWriteLong -- Write a Long by the 68k side
-
- SYNOPSIS
- PPCWriteLong(Address,Value)
- a0 d0
-
- void PPCWriteLong(ULONG*,ULONG);
-
- FUNCTION
- This function writes a long by the 68k processor.
- Quick way to write small amounts of data without cache effects
-
- SEE ALSO
- PPCReadLong()
-
- PowerUPKernel/PPCWriteWord PowerUPKernel/PPCWriteWord
-
- NAME
- PPCWriteWord -- Write a Long by the 68k side
-
- SYNOPSIS
- PPCWriteWord(Address,Value)
- a0 d0
-
- void PPCWriteWord(UWORD*,ULONG);
-
- FUNCTION
- This function writes a long by the 68k processor.
- Quick way to write small amounts of data without cache effects
-
- SEE ALSO
- PPCReadWord()
-
- PowerUPKernel/PPCXor64 PowerUPKernel/PPCXor64
-
- NAME
- PPCXor64 -- Xor 2 64 bit integer values (V46)
-
- SYNOPSIS
- Value = PPCXor64(ValueA , ValueB)
- gpr3:gpr4 gpr3:gpr4 gpr5:gpr6
-
- long long PPCXor64(long long, long long);
-
- FUNCTION
- Xors 2 long long values and returns a long long result.
-
- INPUTS
- ValueA - long long value A
- ValueB - long long value B
-
- RESULT
- Value - long long result
-
- NOTES
- SAS PPC unfortunately has no 64bit integer support, so you
- should look for the PTR functions.
-
- SEE ALSO
- PPCXor64p()
-
- PowerUPKernel/PPCXor64p PowerUPKernel/PPCXor64p
-
- NAME
- PPCXor64p -- Xor 2 64 bit integer values (V46)
-
- SYNOPSIS
- PPCXor64p(ValuePtrA, ValuePtrB)
- gpr3 gpr4
-
- void PPCXor64p(long*,long*);
-
- FUNCTION
- Xors 2 long long values and returns the result at ValuePtrA
-
- INPUTS
- ValuePtrA - ptr to a long long value A
- ValuePtrB - ptr to a long long value B
-
- RESULT
- ValuePtrA - long long result is written to the ValuePtrA address.
-
- SEE ALSO
- PPCXor64()
-
-